get_default_widths (self, &minimum_default, &natural_default);
- layout = gtk_label_get_measuring_layout (self, NULL, natural_default);
+ layout = gtk_label_get_measuring_layout (self, NULL, self->ellipsize ? natural_default : -1);
if (orientation == GTK_ORIENTATION_HORIZONTAL)
{
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <object class="GtkWindow" id="window1">
+ <property name="decorated">0</property>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="label">Hello World</property>
+ </object>
+ </child>
+ </object>
+</interface>
--- /dev/null
+<?xml version="1.0" encoding="UTF-8"?>
+<interface>
+ <object class="GtkWindow" id="window1">
+ <property name="decorated">0</property>
+ <child>
+ <object class="GtkLabel" id="label1">
+ <property name="label">Hello World</property>
+ <property name="max-width-chars">2</property>
+ </object>
+ </child>
+ </object>
+</interface>
'label-sizing.ui',
'label-small-ellipsized.ref.ui',
'label-small-ellipsized.ui',
+ 'label-small-max-width-chars.ref.ui',
+ 'label-small-max-width-chars.ui',
'label-text-shadow-clipping.css',
'label-text-shadow-clipping.ref.ui',
'label-text-shadow-clipping.ui',