summaryrefslogtreecommitdiff
path: root/vcl/unx/gtk4/convert3to4.cxx
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2021-06-08 17:16:01 +0100
committerCaolán McNamara <caolanm@redhat.com>2021-06-09 10:14:56 +0200
commit80f37b8fdc9b3bf39abe437b016cdc69f836058a (patch)
tree6d10375474faa3e61676876241db44de506e6ba5 /vcl/unx/gtk4/convert3to4.cxx
parent6fdd0a3f8b3448a9a246496191908c92156cc38b (diff)
gtk4: default that empty button labels are invisible
Change-Id: If64e9592b48ac376933aac1e30ef76b096a3a0ee Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116859 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'vcl/unx/gtk4/convert3to4.cxx')
-rw-r--r--vcl/unx/gtk4/convert3to4.cxx7
1 files changed, 7 insertions, 0 deletions
diff --git a/vcl/unx/gtk4/convert3to4.cxx b/vcl/unx/gtk4/convert3to4.cxx
index a5282b0cece7..46f5c831b828 100644
--- a/vcl/unx/gtk4/convert3to4.cxx
+++ b/vcl/unx/gtk4/convert3to4.cxx
@@ -1156,8 +1156,15 @@ ConvertResult Convert3To4(const css::uno::Reference<css::xml::dom::XNode>& xNode
xLabelClassName->setValue("GtkLabel");
xNewChildObjectNode->setAttributeNode(xLabelClassName);
if (xChildPropertyLabel)
+ {
xNewChildObjectNode->appendChild(
xChildPropertyLabel->getParentNode()->removeChild(xChildPropertyLabel));
+ }
+ else
+ {
+ auto xNotVisible = CreateProperty(xDoc, "visible", "False");
+ xNewChildObjectNode->appendChild(xNotVisible);
+ }
if (bChildUseUnderline)
{
auto xUseUnderline = CreateProperty(xDoc, "use-underline", "True");