LibreOffice Module sd (master) 1
|
#include <LayerTabBar.hxx>
Public Member Functions | |
LayerTabBar (DrawViewShell *pDrViewSh, vcl::Window *pParent) | |
default constructor More... | |
virtual void | dispose () override |
virtual | ~LayerTabBar () override |
void | SendActivatePageEvent () |
Inform all listeners of this control that the current layer has been activated. More... | |
void | SendDeactivatePageEvent () |
Inform all listeners of this control that the current layer has been deactivated. More... | |
virtual void | InsertPage (sal_uInt16 nPageId, const OUString &rText, TabBarPageBits nBits=TabBarPageBits::NONE, sal_uInt16 nPos=TabBar::APPEND) override |
virtual void | SetPageText (sal_uInt16 nPageId, const OUString &rText) override |
OUString | GetLayerName (sal_uInt16 nPageId) const |
virtual void | Select () override |
virtual void | DoubleClick () override |
virtual SD_DLLPUBLIC void | MouseButtonDown (const MouseEvent &rMEvt) override |
virtual void | Command (const CommandEvent &rCEvt) override |
virtual bool | StartRenaming () override |
virtual TabBarAllowRenamingReturnCode | AllowRenaming () override |
virtual void | EndRenaming () override |
virtual void | ActivatePage () override |
virtual sal_Int8 | AcceptDrop (const AcceptDropEvent &rEvt) override |
AcceptDrop-Event. More... | |
virtual sal_Int8 | ExecuteDrop (const ExecuteDropEvent &rEvt) override |
ExecuteDrop-Event. More... | |
Public Member Functions inherited from TabBar | |
TabBar (vcl::Window *pParent, WinBits nWinStyle, bool bSheets=false) | |
virtual | ~TabBar () override |
virtual void | dispose () override |
virtual void | MouseMove (const MouseEvent &rMEvt) override |
virtual void | MouseButtonDown (const MouseEvent &rMEvt) override |
virtual void | MouseButtonUp (const MouseEvent &rMEvt) override |
virtual void | Paint (vcl::RenderContext &rRenderContext, const tools::Rectangle &rRect) override |
virtual void | Resize () override |
virtual void | RequestHelp (const HelpEvent &rHEvt) override |
virtual void | StateChanged (StateChangedType nStateChange) override |
virtual void | DataChanged (const DataChangedEvent &rDCEvt) override |
virtual bool | PreNotify (NotifyEvent &rNEvt) override |
virtual void | Select () |
virtual void | DoubleClick () |
void | Split () |
virtual void | ActivatePage () |
virtual bool | DeactivatePage () |
virtual bool | StartRenaming () |
virtual TabBarAllowRenamingReturnCode | AllowRenaming () |
virtual void | EndRenaming () |
virtual void | Mirror () |
virtual void | InsertPage (sal_uInt16 nPageId, const OUString &rText, TabBarPageBits nBits=TabBarPageBits::NONE, sal_uInt16 nPos=TabBar::APPEND) |
void | RemovePage (sal_uInt16 nPageId) |
void | MovePage (sal_uInt16 nPageId, sal_uInt16 nNewPos) |
Color | GetTabBgColor (sal_uInt16 nPageId) const |
void | SetTabBgColor (sal_uInt16 nPageId, const Color &aTabBgColor) |
void | Clear () |
bool | IsPageEnabled (sal_uInt16 nPageId) const |
void | SetPageBits (sal_uInt16 nPageId, TabBarPageBits nBits) |
TabBarPageBits | GetPageBits (sal_uInt16 nPageId) const |
sal_uInt16 | GetPageCount () const |
sal_uInt16 | GetPageId (sal_uInt16 nPos) const |
sal_uInt16 | GetPagePos (sal_uInt16 nPageId) const |
sal_uInt16 | GetCurPagePos () const |
sal_uInt16 | GetPageId (const Point &rPos) const |
tools::Rectangle | GetPageRect (sal_uInt16 nPageId) const |
tools::Rectangle | GetPageArea () const |
void | SetCurPageId (sal_uInt16 nPageId) |
sal_uInt16 | GetCurPageId () const |
void | SetFirstPageId (sal_uInt16 nPageId) |
void | MakeVisible (sal_uInt16 nPageId) |
void | SelectPage (sal_uInt16 nPageId, bool bSelect) |
sal_uInt16 | GetSelectPageCount () const |
bool | IsPageSelected (sal_uInt16 nPageId) const |
void | SetProtectionSymbol (sal_uInt16 nPageId, bool bProtection) |
void | SetMaxPageWidth (tools::Long nMaxWidth) |
void | EnableEditMode () |
bool | StartEditMode (sal_uInt16 nPageId) |
void | EndEditMode (bool bCancel=false) |
void | SetEditText (const OUString &rText) |
const OUString & | GetEditText () const |
bool | IsInEditMode () const |
bool | IsEditModeCanceled () const |
sal_uInt16 | GetEditPageId () const |
void | SetMirrored (bool bMirrored) |
bool | IsMirrored () const |
void | SetEffectiveRTL (bool bRTL) |
bool | IsEffectiveRTL () const |
bool | StartDrag (const CommandEvent &rCEvt, vcl::Region &rRegion) |
sal_uInt16 | ShowDropPos (const Point &rPos) |
void | HideDropPos () |
void | SwitchPage (const Point &rPos) |
void | EndSwitchPage () |
virtual void | SetPageText (sal_uInt16 nPageId, const OUString &rText) |
OUString | GetPageText (sal_uInt16 nPageId) const |
OUString | GetHelpText (sal_uInt16 nPageId) const |
tools::Long | GetSplitSize () const |
void | SetStyle (WinBits nStyle) |
WinBits | GetStyle () const |
void | SetScrollAlwaysEnabled (bool bScrollAlwaysEnabled) |
Size | CalcWindowSizePixel () const |
void | SetSelectHdl (const Link< TabBar *, void > &rLink) |
void | SetSplitHdl (const Link< TabBar *, void > &rLink) |
void | SetScrollAreaContextHdl (const Link< const CommandEvent &, void > &rLink) |
void | SetAddButtonEnabled (bool bAddButtonEnabled) |
virtual css::uno::Reference< css::accessibility::XAccessible > | CreateAccessible () override |
Static Public Member Functions | |
static bool | IsRealNameOfStandardLayer (std::u16string_view rName) |
static bool | IsLocalizedNameOfStandardLayer (std::u16string_view rName) |
static OUString | convertToLocalizedName (const OUString &rName) |
Private Member Functions | |
void | SetLayerName (sal_uInt16 nPageId, const OUString &rText) |
Private Attributes | |
DrawViewShell * | pDrViewSh |
Additional Inherited Members | |
Static Public Attributes inherited from TabBar | |
static const sal_uInt16 | APPEND |
static const sal_uInt16 | PAGE_NOT_FOUND |
Protected Member Functions inherited from TabBar | |
virtual void | AddTabClick () |
OUString | GetAuxiliaryText (sal_uInt16 nPageId) const |
void | SetAuxiliaryText (sal_uInt16 nPageId, const OUString &rText) |
Definition at line 37 of file LayerTabBar.hxx.
sd::LayerTabBar::LayerTabBar | ( | DrawViewShell * | pDrViewSh, |
vcl::Window * | pParent | ||
) |
default constructor
Definition at line 47 of file LayerTabBar.cxx.
References TabBar::EnableEditMode(), HID_SD_TABBAR_LAYERS, SetHelpId(), TabBar::SetMaxPageWidth(), WB_3DLOOK, WB_BORDER, and WB_SCROLL.
|
overridevirtual |
Definition at line 58 of file LayerTabBar.cxx.
|
overridevirtual |
AcceptDrop-Event.
Definition at line 263 of file LayerTabBar.cxx.
References sd::DrawViewShell::AcceptDrop(), DND_ACTION_NONE, TabBar::EndSwitchPage(), sd::View::GetDoc(), sd::ViewShell::GetDocSh(), SdrModel::GetLayerAdmin(), SdrLayerAdmin::GetLayerID(), GetLayerName(), TabBar::GetPageId(), sd::ViewShell::GetView(), SfxObjectShell::IsReadOnly(), AcceptDropEvent::maPosPixel, AcceptDropEvent::mbLeaving, pDrViewSh, SDRPAGE_NOTFOUND, and TabBar::SwitchPage().
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 414 of file LayerTabBar.cxx.
References SfxDispatcher::Execute(), SfxViewFrame::GetDispatcher(), sd::ViewShell::GetViewFrame(), and pDrViewSh.
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 333 of file LayerTabBar.cxx.
References Application::CreateMessageDialog(), SdrPaintView::GetActiveLayer(), sd::View::GetDoc(), TabBar::GetEditText(), SfxViewFrame::GetFrameWeld(), SdrLayerAdmin::GetLayer(), SdrModel::GetLayerAdmin(), sd::ViewShell::GetView(), sd::ViewShell::GetViewFrame(), IsLocalizedNameOfStandardLayer(), IsRealNameOfStandardLayer(), pDrViewSh, SdResId(), TABBAR_RENAMING_NO, and TABBAR_RENAMING_YES.
|
overridevirtual |
Definition at line 301 of file LayerTabBar.cxx.
References SfxDispatcher::ExecutePopup(), CommandEvent::GetCommand(), SfxViewFrame::GetDispatcher(), sd::ViewShell::GetViewFrame(), and pDrViewSh.
|
static |
Definition at line 69 of file LayerTabBar.cxx.
References SdResId(), sUNO_LayerName_background, sUNO_LayerName_background_objects, sUNO_LayerName_controls, sUNO_LayerName_layout, and sUNO_LayerName_measurelines.
Referenced by sd::DrawViewShell::GetStatusBarState(), InsertPage(), and SetPageText().
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 63 of file LayerTabBar.cxx.
References TabBar::dispose().
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 250 of file LayerTabBar.cxx.
References SfxDispatcher::Execute(), TabBar::GetCurPageId(), SfxViewFrame::GetDispatcher(), sd::ViewShell::GetViewFrame(), and pDrViewSh.
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 367 of file LayerTabBar.cxx.
References SfxUndoManager::AddUndoAction(), SdrPaintView::GetActiveLayer(), SdrLayer::GetDescription(), sd::View::GetDoc(), SdDrawDocument::GetDocSh(), TabBar::GetEditText(), SdrLayerAdmin::GetLayer(), SdrModel::GetLayerAdmin(), SdrLayer::GetTitle(), sd::ViewShell::GetView(), TabBar::IsEditModeCanceled(), SdrPaintView::IsLayerLocked(), SdrPaintView::IsLayerPrintable(), SdrPaintView::IsLayerVisible(), pDrViewSh, SdrPaintView::SetActiveLayer(), SdDrawDocument::SetChanged(), and SdrLayer::SetName().
|
overridevirtual |
ExecuteDrop-Event.
Definition at line 287 of file LayerTabBar.cxx.
References TabBar::EndSwitchPage(), sd::DrawViewShell::ExecuteDrop(), sd::View::GetDoc(), SdrModel::GetLayerAdmin(), SdrLayerAdmin::GetLayerID(), GetLayerName(), TabBar::GetPageId(), sd::ViewShell::GetView(), ExecuteDropEvent::maPosPixel, pDrViewSh, and SDRPAGE_NOTFOUND.
OUString sd::LayerTabBar::GetLayerName | ( | sal_uInt16 | nPageId | ) | const |
Definition at line 90 of file LayerTabBar.cxx.
References TabBar::GetAuxiliaryText(), and nPageId.
Referenced by AcceptDrop(), sd::DrawViewShell::DeleteActualLayer(), ExecuteDrop(), sd::DrawViewShell::FuTemporary(), sd::DrawViewShell::GetMenuState(), MouseButtonDown(), sd::DrawViewShell::ResetActualLayer(), sd::DrawViewShell::SetActiveTabLayerIndex(), and StartRenaming().
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 101 of file LayerTabBar.cxx.
References convertToLocalizedName(), TabBar::InsertPage(), nPageId, nPos, and SetLayerName().
Referenced by sd::DrawViewShell::ResetActualLayer().
|
static |
Definition at line 116 of file LayerTabBar.cxx.
References SdResId().
Referenced by AllowRenaming(), and sd::DrawViewShell::FuTemporary().
|
static |
Definition at line 125 of file LayerTabBar.cxx.
References sUNO_LayerName_background, sUNO_LayerName_background_objects, sUNO_LayerName_controls, sUNO_LayerName_layout, and sUNO_LayerName_measurelines.
Referenced by AllowRenaming(), sd::DrawViewShell::DeleteActualLayer(), sd::DrawViewShell::FuTemporary(), sd::DrawViewShell::GetMenuState(), and StartRenaming().
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 140 of file LayerTabBar.cxx.
References SfxUndoManager::AddUndoAction(), aName, SfxDispatcher::Execute(), TabBar::GetCurPageId(), SdrLayer::GetDescription(), SfxViewFrame::GetDispatcher(), sd::View::GetDoc(), SdDrawDocument::GetDocSh(), SdrLayerAdmin::GetLayer(), SdrModel::GetLayerAdmin(), GetLayerName(), TabBar::GetPageId(), MouseEvent::GetPosPixel(), SdrPaintView::GetSdrPageView(), SdrLayer::GetTitle(), sd::ViewShell::GetView(), sd::ViewShell::GetViewFrame(), SdrPageView::IsLayerLocked(), SdrPageView::IsLayerPrintable(), SdrPageView::IsLayerVisible(), MouseEvent::IsLeft(), MouseEvent::IsMod1(), MouseEvent::IsMod2(), MouseEvent::IsShift(), MOUSE_LEFT, TabBar::MouseButtonDown(), pDrViewSh, sd::DrawViewShell::ResetActualLayer(), SdDrawDocument::SetChanged(), SdrPageView::SetLayerLocked(), SdrPageView::SetLayerPrintable(), and SdrPageView::SetLayerVisible().
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 134 of file LayerTabBar.cxx.
References SfxDispatcher::Execute(), SfxViewFrame::GetDispatcher(), sd::ViewShell::GetViewFrame(), and pDrViewSh.
void sd::LayerTabBar::SendActivatePageEvent | ( | ) |
Inform all listeners of this control that the current layer has been activated.
Call this method after switching the current layer and is not done elsewhere (like when using ctrl + page up/down keys).
Definition at line 424 of file LayerTabBar.cxx.
References TabBar::GetCurPageId().
Referenced by sd::FuPoor::SwitchLayer().
void sd::LayerTabBar::SendDeactivatePageEvent | ( | ) |
Inform all listeners of this control that the current layer has been deactivated.
Call this method before switching the current layer and is not done elsewhere (like when using ctrl page up/down keys).
Definition at line 430 of file LayerTabBar.cxx.
References TabBar::GetCurPageId().
Referenced by sd::FuPoor::SwitchLayer().
|
private |
Definition at line 95 of file LayerTabBar.cxx.
References nPageId, and TabBar::SetAuxiliaryText().
Referenced by InsertPage(), and SetPageText().
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 109 of file LayerTabBar.cxx.
References convertToLocalizedName(), nPageId, SetLayerName(), and TabBar::SetPageText().
Referenced by sd::DrawViewShell::ModifyLayer().
|
overridevirtual |
Reimplemented from TabBar.
Definition at line 310 of file LayerTabBar.cxx.
References TabBar::GetEditPageId(), GetLayerName(), sd::ViewShell::GetView(), IsRealNameOfStandardLayer(), SdrObjEditView::IsTextEdit(), pDrViewSh, and sd::View::SdrEndTextEdit().
|
private |
Definition at line 100 of file LayerTabBar.hxx.
Referenced by AcceptDrop(), ActivatePage(), AllowRenaming(), Command(), DoubleClick(), EndRenaming(), ExecuteDrop(), MouseButtonDown(), Select(), and StartRenaming().