[Libreoffice-commits] core.git: Branch 'libreoffice-5-1' - cui/source cui/uiconfig
Caolán McNamara
caolanm at redhat.com
Tue Apr 19 08:10:58 UTC 2016
cui/source/dialogs/postdlg.cxx | 7 +++----
cui/uiconfig/ui/comment.ui | 11 -----------
2 files changed, 3 insertions(+), 15 deletions(-)
New commits:
commit 2407399c0c840c2e3d9de6575a99695967e88039
Author: Caolán McNamara <caolanm at redhat.com>
Date: Mon Apr 18 13:54:15 2016 +0100
postit dialog is too tall
the initial size hack has come unstuck, do it the now-standard
way or explicitly setting an initial size in code
Change-Id: I89c73e433b1974514fa2a68eb9bd5373142c313a
(cherry picked from commit 2b9a215805ef50c1af727721d78465398ad53223)
Reviewed-on: https://gerrit.libreoffice.org/24217
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>
diff --git a/cui/source/dialogs/postdlg.cxx b/cui/source/dialogs/postdlg.cxx
index 1b69f93..d0a7c5c 100644
--- a/cui/source/dialogs/postdlg.cxx
+++ b/cui/source/dialogs/postdlg.cxx
@@ -109,10 +109,9 @@ SvxPostItDialog::SvxPostItDialog(vcl::Window* pParent, const SfxItemSet& rCoreSe
ShowLastAuthor(aAuthorStr, aDateStr);
- //lock to initial .ui placeholder size before replacing contents
- Size aSize(m_pEditED->get_preferred_size());
- m_pEditED->set_width_request(aSize.Width());
- m_pEditED->set_height_request(aSize.Height());
+ //lock to an initial size before replacing contents
+ m_pEditED->set_width_request(m_pEditED->approximate_char_width() * 40);
+ m_pEditED->set_height_request(m_pEditED->GetTextHeight() * 10);
m_pEditED->SetText(convertLineEnd(aTextStr, GetSystemLineEnd()));
diff --git a/cui/uiconfig/ui/comment.ui b/cui/uiconfig/ui/comment.ui
index f00b628..f25f37f 100644
--- a/cui/uiconfig/ui/comment.ui
+++ b/cui/uiconfig/ui/comment.ui
@@ -206,7 +206,6 @@
<property name="hexpand">True</property>
<property name="vexpand">True</property>
<property name="wrap_mode">char</property>
- <property name="buffer">textbuffer1</property>
</object>
</child>
</object>
@@ -309,14 +308,4 @@
<property name="can_focus">False</property>
<property name="stock">gtk-go-forward</property>
</object>
- <object class="GtkTextBuffer" id="textbuffer1">
- <property name="text">12345678901234567890123456789012345
-2
-3
-4
-5
-6
-7
-8</property>
- </object>
</interface>
More information about the Libreoffice-commits
mailing list