// $Header$ #include "QuadSetEditor.h" #include #include #include #include #include #include #include #include #include #include #include using namespace Reve; //______________________________________________________________________ // QuadSetEditor // ClassImp(QuadSetEditor) QuadSetEditor::QuadSetEditor(const TGWindow *p, Int_t width, Int_t height, UInt_t options, Pixel_t back) : TGedFrame(p, width, height, options | kVerticalFrame, back), fM(0), fHMTrans (0), fPalette (0) // Initialize widget pointers to 0 { MakeTitle("Transformation matrix"); fHMTrans = new ZTransSubEditor(this); fHMTrans->Connect("UseTrans()", "Reve::QuadSetEditor", this, "Update()"); fHMTrans->Connect("TransChanged()", "Reve::QuadSetEditor", this, "Update()"); AddFrame(fHMTrans, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0, 0, 0)); MakeTitle("Palette controls"); fPalette = new RGBAPaletteSubEditor(this); fPalette->Connect("Changed", "Reve::QuadSetEditor", this, "Update()"); AddFrame(fPalette, new TGLayoutHints(kLHintsTop | kLHintsExpandX, 2, 0, 0, 0)); MakeTitle("QuadSet"); // Create widgets // fXYZZ = new TGSomeWidget(this, ...); // AddFrame(fXYZZ, new TGLayoutHints(...)); // fXYZZ->Connect("SignalName()", "Reve::QuadSetEditor", this, "DoXYZZ()"); } QuadSetEditor::~QuadSetEditor() {} /**************************************************************************/ void QuadSetEditor::SetModel(TObject* obj) { fM = dynamic_cast(obj); fHMTrans->SetDataFromTrans(&fM->fHMTrans); fPalette->SetModel(fM->fPalette); // Set values of widgets // fXYZZ->SetValue(fM->GetXYZZ()); } /**************************************************************************/ // Implements callback/slot methods // void QuadSetEditor::DoXYZZ() // { // fM->SetXYZZ(fXYZZ->GetValue()); // Update(); // }