12#ifndef ROOT_TGuiBldDragManager
13#define ROOT_TGuiBldDragManager
Handle_t Window_t
Window handle.
virtual RooAbsTestStatistic * create(const char *name, const char *title, RooAbsReal &real, RooAbsData &data, const RooArgSet &projDeps, Configuration const &cfg)=0
#define ClassDefOverride(name, id)
winID h TVirtualViewer3D TVirtualGLPainter p
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t ChangeProperties
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void on
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t win
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t src
A frame containing two scrollbars (a horizontal and a vertical) and a viewport.
A full featured color selection dialog.
A combobox (also known as a drop down listbox) allows the selection of one item out of a list of item...
The base class for composite widgets (menu bars, list boxes, etc.).
Font selection dialog, allowing to select one in the list of available fonts in the system.
A subclasses of TGWindow, and is used as base class for some simple widgets (buttons,...
A composite frame with a border and a title.
This class handles GUI icons.
This class handles GUI labels.
This class describes layout hints used by the layout classes.
A listbox is a box, possibly with scrollbar, containing entries.
Defines top level windows that interact with the system Window Manager.
The classes in this file implement progress bars.
Yield an action as soon as it is clicked.
A TGTextEntry is a one line text input widget.
ROOT GUI Window base class.
@ kEditDisableResize
window size cannot be edited
@ kEditDisableHeight
window height cannot be edited
@ kEditDisableLayout
window layout cannot be edited
@ kEditDisableWidth
window width cannot be edited
@ kEditDisableGrab
window grab cannot be edited
@ kEditDisable
disable edit of this window
@ kEditDisableEvents
window events cannot be edited
Drag and drop manager used by the ROOT GUI Builder.
Bool_t IsLassoDrawn() const
TGFrame * GetEditableParent(TGFrame *f)
Return the parent frame which can be edited.
void ChangeSelected(TGFrame *f)
Inform outside wold that selected frame was changed.
Bool_t HandleEvent(Event_t *) override
Handle all events.
Bool_t EndDrag() override
End dragging.
void HandleAction(Int_t act)
Main handler of actions.
Bool_t IsFixedH(TGWindow *f) const
void DoDialogCancel()
Process dialog Cancel button pressed.
void DeleteMenuDialog()
Delete dialog and trash.
void SetCursorType(Int_t cur)
Set cursor for selected/grabbed frame.
void SwitchLayout()
Switch Horizontal/Vertical layout of selected/grabbed composite frame.
void SetBuilder(TRootGuiBuilder *b)
void ChangeImage(TGIcon *)
Invoke file dialog to assign a new image.
void DoClassMenu(Int_t)
Process a method chosen via frame context menu.
Bool_t IsMoveWaiting() const
Waits for either the mouse move from the given initial ButtonPress location or for the mouse button t...
void ChangeTextFont(TGGroupFrame *)
Change text font via font selection dialog.
Bool_t CheckDragResize(Event_t *event)
Check resize type event.
void SelectFrame(TGFrame *frame, Bool_t add=kFALSE)
Grab/Select frame.
TGFrame * InEditable(Window_t id)
Return a pointer to the parent window (which is being edited)
Bool_t CanChangeLayoutOrder(TGWindow *w) const
kTRUE - if it's possible to change layout order in the parent's layout of window w
Bool_t Cancel(Bool_t delSrc) override
Do cancel action.
void HandlePaste()
Handle paste action.
void Snap2Grid()
Draw grid on editable frame and restore background on previously edited one.
Bool_t IsPointVisible(Int_t x, Int_t y)
Helper function for IsSelectedWindow method.
void PutToCanvas(TGCompositeFrame *cont)
Create a new TGCanvas and place container into it.
void CheckTargetUnderGrab()
Look for the drop target under grabbed/selected frame while moving.
void HideGrabRectangles()
Hide/Unmap grab rectangles.
Int_t GetEndDragX() const override
Return the current X coordinate of the dragged frame.
void CreatePropertyEditor()
Create widget property editor (it could be located outside of guibuilder)
void SetGridStep(UInt_t step)
Set the grid step.
Bool_t HandleButton(Event_t *) override
Handle button event occurred in some ROOT frame.
void Compact(Bool_t global=kTRUE)
Layout and Resize frame.
void DrawLasso()
Draw lasso for allocation new object.
void Menu4Frame(TGFrame *, Int_t x, Int_t y)
Create and place context menu for selected frame.
void RaiseMdiFrame(TGFrame *in)
Raise guibuilder's mdi frame.
void DeleteFrame(TGFrame *frame)
Delete frame.
void DoDialogApply()
Process dialog Apply button pressed.
void DoMove()
Handle move.
Bool_t IgnoreEvent(Event_t *e) override
Return kTRUE if event is rejected for processing by drag manager.
void ChangeBarColor(TGProgressBar *)
Set progress bar color via TGColorDialog.
void HandleDelete(Bool_t crop=kFALSE)
Handle delete or crop action.
void Menu4Lasso(Int_t x, Int_t y)
Create context menu for lasso actions.
Int_t GetEndDragY() const override
Returns the current Y coordinate of the dragged frame.
void ReparentFrames(TGFrame *newfr, TGCompositeFrame *oldfr)
Reparent frames.
Bool_t HandleExpose(Event_t *) override
Handle repaint event.
void HandleLayoutOrder(Bool_t forward=kTRUE)
Change layout order.
void CloneEditable()
Create a frame which is the same as currently edited frame.
void HandleReplace()
Handle replace.
void DoDialogOK()
Process dialog OK button pressed.
TList * GetFramesInside(Int_t x0, Int_t y0, Int_t x, Int_t y)
Return the list of frames inside of some area.
void DoResize()
handle resize
Int_t GetStrartDragX() const override
Return the X coordinate where drag started.
Int_t GetStrartDragY() const override
Return the Y coordinate where drag started.
TGCompositeFrame * FindCompositeFrame(Window_t id)
Find the first composite parent of window.
Bool_t HandleButtonPress(Event_t *)
Handle button press event.
Bool_t GetDropStatus() const
void HandleButon3Pressed(Event_t *, TGFrame *frame=nullptr)
Handle 3d mouse pressed (popup context menu)
void TimerEvent(Event_t *ev)
void HandleAlignment(Int_t to, Bool_t lineup=kFALSE)
Align frames located inside lasso area.
Bool_t SaveFrame(const char *file=nullptr)
Save composite frame as macro.
void SwitchEditable(TGFrame *frame)
Switch editable.
void DrawGrabRect(Int_t i, Int_t x, Int_t y)
Helper method to draw grab rectangle at position x,y.
void SetEditable(Bool_t on=kTRUE) override
Grab server.
TGFrame * GetTarget() const
void UnmapAllPopups()
Unmap all popups.
void ChangePicture(TGPictureButton *)
Invoke file dialog to assign a new picture.
Bool_t IsEditDisabled(TGWindow *f) const
TGFrame * FindMdiFrame(TGFrame *in)
Return a pointer to the parent mdi frame.
Bool_t HandleTimerEvent(Event_t *ev, TTimer *t) override
Handle timer events or events coming from the recorder.
void ChangeBackgroundColor(TGListBox *)
Set background color for list box entries.
Bool_t HandleSelectionRequest(Event_t *) override
not used yet.
TGuiBldDragManagerPimpl * fPimpl
Bool_t CanCompact(TGWindow *w) const
kTRUE is frame could be compacted/"laid out"
void CloseMenus()
Helper to close all menus.
void GrabFrame(TGFrame *frame)
grab frame (see SelectFrame)
void AddClassMenuMethods(TGPopupMenu *menu, TObject *object)
Add entries with class //*MENU* methods.
void HandleCopy(Bool_t brk_layout=kTRUE)
Handle copy.
void ToGrid(Int_t &x, Int_t &y)
Return grid coordinates which are close to given.
void CreateListOfDialogs()
Create a list of dialog methods.
static TGFontDialog * fgGlobalFontDialog
void SetLassoDrawn(Bool_t on)
Set lasso drawn flag.
Bool_t IsFixedW(TGWindow *f) const
void HandleCut()
Handle cut action.
TGWindow * GetResizableParent(TGWindow *p)
Find parent frame which can be resized.
Bool_t Drop() override
Drop grabbed frame.
static void MapGlobalDialog(TGMainFrame *dialog, TGFrame *fr)
Map dialog and place it relative to selected frame.
void HandleReturn(Bool_t on=kFALSE)
Handling of return/enter key pressing.
UInt_t GetGridStep()
Return the grid step.
Bool_t HandleButtonRelease(Event_t *)
Handle button release event.
static TGFontDialog * GetGlobalFontDialog()
Create global font dialog.
void Reset1()
Reset some parameters.
Bool_t HandleDestroyNotify(Event_t *)
Handle destroy notify.
Bool_t HandleClientMessage(Event_t *) override
Handle client message.
Bool_t HandleSelection(Event_t *) override
not used yet.
void PlaceFrame(TGFrame *, TGLayoutHints *)
Put created frame at position of the last mouse click.
Bool_t IsFixedLayout(TGWindow *f) const
Bool_t HandleTimer(TTimer *) override
The main event loop is originated here It repeatedly queries pointer state and position on the screen...
void SetPropertyEditor(TGuiBldEditor *e)
Helper method.
Bool_t CheckTargetAtPoint(Int_t x, Int_t y)
Helper. Look for the drop target under grabbed/selected frame while moving.
TGFrame * GetMovableParent(TGWindow *p)
Find parent frame which can be dragged.
Bool_t HandleMotion(Event_t *) override
Handle motion event.
void DrawGrabRectangles(TGWindow *win=nullptr)
Draw small grab rectangles around grabbed/selected/frame.
static TGColorDialog * fgGlobalColorDialog
void DoRedraw() override
Redraw the edited window.
Bool_t IsFixedSize(TGWindow *f) const
~TGuiBldDragManager() override
Destructor.
void HighlightCompositeFrame(Window_t)
Raise composite frame when mouse is moving over it.
Bool_t HandleConfigureNotify(Event_t *) override
Resize events.
void DoReplace(TGFrame *frame)
Replace frame (doesn't work yet properly)
Bool_t StartDrag(TGFrame *src, Int_t x, Int_t y) override
Start dragging.
void HandleGrid()
Switch on/of grid drawn.
Bool_t CanChangeLayout(TGWindow *w) const
kTRUE - if it's possible to switch disable/enable layout
Bool_t Save(const char *file="")
Save an edited frame to the file.
void BreakLayout()
Disable/Enable layout for selected/grabbed composite frame.
Bool_t IsPasteFrameExist()
Return kTRUE if paste frame exist.
void UngrabFrame()
Ungrab/Unselect selected/grabbed frame.
Bool_t HandleKey(Event_t *) override
Handle key event.
TRootGuiBuilder * fBuilder
void DropCanvas(TGCanvas *canvas)
Drop canvas container.
Bool_t IsEventsDisabled(TGWindow *f) const
void AddDialogMethods(TGPopupMenu *menu, TObject *object)
Add DIALOG entries to the selected frame popup menu.
Bool_t IsSelectedVisible()
Return kTRUE if grabbed/selected frame is not overlapped by other windows.
Bool_t RecognizeGesture(Event_t *, TGFrame *frame=nullptr)
Recognize what was done when mouse button pressed.
void DeletePropertyEditor()
Delete widget property editor.
static TGColorDialog * GetGlobalColorDialog(Bool_t create=kTRUE)
Return pointer to global color dialog.
TGCompositeFrame * FindLayoutFrame(TGFrame *f)
Helper to find a frame which can be laid out.
TGFrame * GetBtnEnableParent(TGFrame *fr)
Return a parent which can handle button events.
TGFrame * GetSelected() const
Return the current grabbed/selected frame.
void HandleUpdateSelected(TGFrame *)
When selected frame was changed by guibuilder editor -> update its appearance.
Bool_t IsGrabDisabled(TGWindow *f) const
void ChangeTextColor(TGGroupFrame *)
Change text color via color selection dialog.
Bool_t HandleDoubleClick(Event_t *) override
Mouse double click handler (never should happen)
Mother of all ROOT objects.
void Emit(const char *signal, const T &arg)
Activate signal with single parameter.
Recorder of operations for undo and redo.
Handles synchronous and a-synchronous timer events.
TGFrame * fTarget
drop target