Printers: fix panel width
This commit is contained in:
parent
cdf6311f63
commit
79752c921a
2 changed files with 41 additions and 65 deletions
|
@ -432,8 +432,6 @@ printer_selection_changed_cb (GtkTreeSelection *selection,
|
|||
widget = (GtkWidget*)
|
||||
gtk_builder_get_object (priv->builder, "supply-drawing-area");
|
||||
|
||||
width = gtk_widget_get_allocated_width (widget);
|
||||
|
||||
if (marker_levels)
|
||||
{
|
||||
gchar **marker_levelsv = NULL;
|
||||
|
@ -443,17 +441,15 @@ printer_selection_changed_cb (GtkTreeSelection *selection,
|
|||
|
||||
marker_levelsv = g_strsplit (marker_levels, ",", -1);
|
||||
gtk_widget_set_size_request (widget,
|
||||
width,
|
||||
-1,
|
||||
((g_strv_length (marker_levelsv) - 1) * SUPPLY_BAR_SPACE
|
||||
+ g_strv_length (marker_levelsv) * SUPPLY_BAR_HEIGHT));
|
||||
g_strfreev (marker_levelsv);
|
||||
}
|
||||
else
|
||||
gtk_widget_set_size_request (widget, 0, 0);
|
||||
gtk_widget_set_size_request (widget, -1, -1);
|
||||
|
||||
width = gtk_widget_get_allocated_width (widget);
|
||||
height = gtk_widget_get_allocated_height (widget);
|
||||
gtk_widget_queue_draw_area (widget, 0, 0, width, height);
|
||||
gtk_widget_queue_draw (widget);
|
||||
|
||||
|
||||
widget = (GtkWidget*)
|
||||
|
|
|
@ -470,19 +470,33 @@
|
|||
<child>
|
||||
<object class="GtkTable" id="table3">
|
||||
<property name="visible">True</property>
|
||||
<property name="n_columns">4</property>
|
||||
<property name="homogeneous">True</property>
|
||||
<property name="n_columns">3</property>
|
||||
<child>
|
||||
<object class="GtkButton" id="back-button-1">
|
||||
<property name="label" translatable="yes" comments="Translators: Switch back to printer's info tab">Back</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">True</property>
|
||||
<property name="halign">GTK_ALIGN_START</property>
|
||||
<property name="valign">GTK_ALIGN_CENTER</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="x_options">GTK_FILL</property>
|
||||
<property name="y_options">GTK_FILL</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label1">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes" comments="Translators: This tab contains list of active print jobs of the selected printer">Active Print Jobs</property>
|
||||
<property name="halign">GTK_ALIGN_CENTER</property>
|
||||
<property name="valign">GTK_ALIGN_CENTER</property>
|
||||
<attributes>
|
||||
<attribute name="weight" value="bold"/>
|
||||
</attributes>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="x_options"></property>
|
||||
<property name="y_options">GTK_FILL</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
@ -491,35 +505,11 @@
|
|||
<property name="visible">True</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">3</property>
|
||||
<property name="right_attach">4</property>
|
||||
<property name="x_options"></property>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="x_options">GTK_FILL</property>
|
||||
<property name="y_options">GTK_FILL</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkHBox" id="hbox2">
|
||||
<property name="visible">True</property>
|
||||
<child>
|
||||
<object class="GtkButton" id="back-button-1">
|
||||
<property name="label" translatable="yes" comments="Translators: Switch back to printer's info tab">Back</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">True</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="y_options">GTK_FILL</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
|
@ -625,19 +615,33 @@
|
|||
<child>
|
||||
<object class="GtkTable" id="table2">
|
||||
<property name="visible">True</property>
|
||||
<property name="n_columns">4</property>
|
||||
<property name="homogeneous">True</property>
|
||||
<property name="n_columns">3</property>
|
||||
<child>
|
||||
<object class="GtkButton" id="back-button-2">
|
||||
<property name="label" translatable="yes" comments="Translators: Switch back to printer's info tab">Back</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">True</property>
|
||||
<property name="halign">GTK_ALIGN_START</property>
|
||||
<property name="valign">GTK_ALIGN_CENTER</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="x_options">GTK_FILL</property>
|
||||
<property name="y_options">GTK_FILL</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="label6">
|
||||
<property name="visible">True</property>
|
||||
<property name="label" translatable="yes" comments="Translators: This tab contains list of active print jobs of the selected printer">Printer Options</property>
|
||||
<property name="halign">GTK_ALIGN_CENTER</property>
|
||||
<property name="valign">GTK_ALIGN_CENTER</property>
|
||||
<attributes>
|
||||
<attribute name="weight" value="bold"/>
|
||||
</attributes>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="x_options"></property>
|
||||
<property name="y_options">GTK_FILL</property>
|
||||
</packing>
|
||||
</child>
|
||||
|
@ -646,35 +650,11 @@
|
|||
<property name="visible">True</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">3</property>
|
||||
<property name="right_attach">4</property>
|
||||
<property name="x_options"></property>
|
||||
<property name="left_attach">2</property>
|
||||
<property name="x_options">GTK_FILL</property>
|
||||
<property name="y_options">GTK_FILL</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkHBox" id="hbox3">
|
||||
<property name="visible">True</property>
|
||||
<child>
|
||||
<object class="GtkButton" id="back-button-2">
|
||||
<property name="label" translatable="yes" comments="Translators: Switch back to printer's info tab">Back</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">True</property>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
<property name="position">0</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="y_options">GTK_FILL</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<placeholder/>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="expand">False</property>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue