[Libreoffice-commits] core.git: svx/source svx/uiconfig
Pranam Lashkari (via logerrit)
logerrit at kemper.freedesktop.org
Mon May 11 21:01:05 UTC 2020
svx/source/sidebar/text/TextPropertyPanel.cxx | 6 ++++++
svx/source/sidebar/text/TextPropertyPanel.hxx | 2 ++
svx/uiconfig/ui/sidebartextpanel.ui | 25 +++++++++++++++++++++++++
3 files changed, 33 insertions(+)
New commits:
commit a0e45956ce90401be01918f4712ae187beccf248
Author: Pranam Lashkari <lpranam at collabora.com>
AuthorDate: Thu May 7 19:21:04 2020 +0530
Commit: Andras Timar <andras.timar at collabora.com>
CommitDate: Mon May 11 23:00:28 2020 +0200
fixed clear Direct Formatting button to sidebar in impress
Change-Id: I81cd30b3ce7087122c260dca99e86a3c857447b2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93813
Tested-by: Jenkins
Reviewed-by: Andras Timar <andras.timar at collabora.com>
diff --git a/svx/source/sidebar/text/TextPropertyPanel.cxx b/svx/source/sidebar/text/TextPropertyPanel.cxx
index 6c3b20cedef6..642f41800718 100644
--- a/svx/source/sidebar/text/TextPropertyPanel.cxx
+++ b/svx/source/sidebar/text/TextPropertyPanel.cxx
@@ -57,6 +57,8 @@ TextPropertyPanel::TextPropertyPanel ( vcl::Window* pParent, const css::uno::Ref
, mxToolBoxBackgroundColorDispatch(new ToolbarUnoDispatcher(*mxToolBoxBackgroundColor, *m_xBuilder, rxFrame))
, mxResetBar(m_xBuilder->weld_toolbar("resetattr"))
, mxResetBarDispatch(new ToolbarUnoDispatcher(*mxResetBar, *m_xBuilder, rxFrame))
+ , mxDefaultBar(m_xBuilder->weld_toolbar("defaultattr"))
+ , mxDefaultBarDispatch(new ToolbarUnoDispatcher(*mxDefaultBar, *m_xBuilder, rxFrame))
, mxPositionBar(m_xBuilder->weld_toolbar("position"))
, mxPositionBarDispatch(new ToolbarUnoDispatcher(*mxPositionBar, *m_xBuilder, rxFrame))
, mxSpacingBar(m_xBuilder->weld_toolbar("spacingbar"))
@@ -78,6 +80,7 @@ TextPropertyPanel::~TextPropertyPanel()
void TextPropertyPanel::dispose()
{
mxResetBarDispatch.reset();
+ mxDefaultBarDispatch.reset();
mxPositionBarDispatch.reset();
mxSpacingBarDispatch.reset();
mxToolBoxFontColorSwDispatch.reset();
@@ -89,6 +92,7 @@ void TextPropertyPanel::dispose()
mxFontDispatch.reset();
mxResetBar.reset();
+ mxDefaultBar.reset();
mxPositionBar.reset();
mxSpacingBar.reset();
mxToolBoxFontColorSw.reset();
@@ -140,6 +144,8 @@ void TextPropertyPanel::HandleContextChange (
mxToolBoxFontColor->set_visible(!bWriterText);
mxToolBoxFontColorSw->set_visible(bWriterText);
mxToolBoxBackgroundColor->set_visible(bDrawText);
+ mxResetBar->set_visible(bWriterText);
+ mxDefaultBar->set_visible(bDrawText);
}
} // end of namespace svx::sidebar
diff --git a/svx/source/sidebar/text/TextPropertyPanel.hxx b/svx/source/sidebar/text/TextPropertyPanel.hxx
index baea3468f9de..437596145584 100644
--- a/svx/source/sidebar/text/TextPropertyPanel.hxx
+++ b/svx/source/sidebar/text/TextPropertyPanel.hxx
@@ -62,6 +62,8 @@ private:
std::unique_ptr<ToolbarUnoDispatcher> mxToolBoxBackgroundColorDispatch;
std::unique_ptr<weld::Toolbar> mxResetBar;
std::unique_ptr<ToolbarUnoDispatcher> mxResetBarDispatch;
+ std::unique_ptr<weld::Toolbar> mxDefaultBar;
+ std::unique_ptr<ToolbarUnoDispatcher> mxDefaultBarDispatch;
std::unique_ptr<weld::Toolbar> mxPositionBar;
std::unique_ptr<ToolbarUnoDispatcher> mxPositionBarDispatch;
std::unique_ptr<weld::Toolbar> mxSpacingBar;
diff --git a/svx/uiconfig/ui/sidebartextpanel.ui b/svx/uiconfig/ui/sidebartextpanel.ui
index 14584cdc63d1..943cf41b1165 100644
--- a/svx/uiconfig/ui/sidebartextpanel.ui
+++ b/svx/uiconfig/ui/sidebartextpanel.ui
@@ -337,6 +337,31 @@
<property name="position">3</property>
</packing>
</child>
+ <child>
+ <object class="GtkToolbar" id="defaultattr">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="toolbar_style">icons</property>
+ <property name="show_arrow">False</property>
+ <property name="icon_size">2</property>
+ <child>
+ <object class="GtkToolButton" id=".uno:SetDefault">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="homogeneous">False</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
<child>
<object class="GtkToolbar" id="position">
<property name="visible">True</property>
More information about the Libreoffice-commits
mailing list