Commit 615b641a authored by Havoc Pennington's avatar Havoc Pennington Committed by Havoc Pennington

don't try to handle alignment here, because it's done by PangoLayout after

2001-09-20  Havoc Pennington  <hp@redhat.com>

	* gtk/gtktextlayout.c (gtk_text_layout_get_line_display): don't
	try to handle alignment here, because it's done by PangoLayout
	after we set the layout width. Fix from Dov.
parent ed7aefc3
2001-09-20 Havoc Pennington <hp@redhat.com>
* gtk/gtktextlayout.c (gtk_text_layout_get_line_display): don't
try to handle alignment here, because it's done by PangoLayout
after we set the layout width. Fix from Dov.
2001-09-21 Hans Breuer <hans@breuer.org>
* gdk/gdk.def :
......
2001-09-20 Havoc Pennington <hp@redhat.com>
* gtk/gtktextlayout.c (gtk_text_layout_get_line_display): don't
try to handle alignment here, because it's done by PangoLayout
after we set the layout width. Fix from Dov.
2001-09-21 Hans Breuer <hans@breuer.org>
* gdk/gdk.def :
......
2001-09-20 Havoc Pennington <hp@redhat.com>
* gtk/gtktextlayout.c (gtk_text_layout_get_line_display): don't
try to handle alignment here, because it's done by PangoLayout
after we set the layout width. Fix from Dov.
2001-09-21 Hans Breuer <hans@breuer.org>
* gdk/gdk.def :
......
2001-09-20 Havoc Pennington <hp@redhat.com>
* gtk/gtktextlayout.c (gtk_text_layout_get_line_display): don't
try to handle alignment here, because it's done by PangoLayout
after we set the layout width. Fix from Dov.
2001-09-21 Hans Breuer <hans@breuer.org>
* gdk/gdk.def :
......
2001-09-20 Havoc Pennington <hp@redhat.com>
* gtk/gtktextlayout.c (gtk_text_layout_get_line_display): don't
try to handle alignment here, because it's done by PangoLayout
after we set the layout width. Fix from Dov.
2001-09-21 Hans Breuer <hans@breuer.org>
* gdk/gdk.def :
......
2001-09-20 Havoc Pennington <hp@redhat.com>
* gtk/gtktextlayout.c (gtk_text_layout_get_line_display): don't
try to handle alignment here, because it's done by PangoLayout
after we set the layout width. Fix from Dov.
2001-09-21 Hans Breuer <hans@breuer.org>
* gdk/gdk.def :
......
2001-09-20 Havoc Pennington <hp@redhat.com>
* gtk/gtktextlayout.c (gtk_text_layout_get_line_display): don't
try to handle alignment here, because it's done by PangoLayout
after we set the layout width. Fix from Dov.
2001-09-21 Hans Breuer <hans@breuer.org>
* gdk/gdk.def :
......
......@@ -1793,6 +1793,19 @@ arrow.
@show_toggle_indicator: unused
@show_submenu_indicator: whether to show the arrow or not
<!-- ##### FUNCTION gtk_menu_item_set_placement ##### -->
<para>
Specifies the placement of the submenu around the menu item. The placement
is usually #GTK_LEFT_RIGHT for menu items in a popup menu and
#GTK_TOP_BOTTOM in menu bars.
</para>
<para>
This function is useless in usual applications.
</para>
@menu_item: the menu item
@placement: the submenu placement
<!-- ##### FUNCTION gtk_object_arg_get ##### -->
<para>
Private function to get an argument and argument info from an object.
......@@ -2480,6 +2493,15 @@ fundamental type.
@group_cycling:
@Returns:
<!-- ##### FUNCTION gtk_widget_get_usize ##### -->
<para>
</para>
@widget:
@width:
@height:
<!-- ##### FUNCTION gtk_widget_pop_style ##### -->
<para>
......
......@@ -96,9 +96,9 @@ Creates a new #GtkMenu.
Adds a new #GtkMenuItem to the end of the menu's item list.
</para>
<!-- # Unused Parameters # -->
@menu: a #GtkMenu.
@child: The #GtkMenuItem to add.
<!-- # Unused Parameters # -->
@m:
@c:
......@@ -108,8 +108,8 @@ Adds a new #GtkMenuItem to the end of the menu's item list.
Adds a new #GtkMenuItem to the beginning of the menu's item list.
</para>
@menu_child:
<!-- # Unused Parameters # -->
@menu_child:
@m:
@c:
@menu: a #GtkMenu.
......@@ -122,10 +122,10 @@ Adds a new #GtkMenuItem to the menu's item list at the position
indicated by @position.
</para>
<!-- # Unused Parameters # -->
@menu: a #GtkMenu.
@child: The #GtkMenuItem to add.
@pos:
<!-- # Unused Parameters # -->
@position: The position in the item list where @child is added.
Positions are numbered from 0 to n-1.
......
......@@ -91,20 +91,6 @@ Removes the widget's submenu.
@menu_item: the menu item widget
<!-- ##### FUNCTION gtk_menu_item_set_placement ##### -->
<para>
Specifies the placement of the submenu around the menu item. The placement
is usually #GTK_LEFT_RIGHT for menu items in a popup menu and
#GTK_TOP_BOTTOM in menu bars.
</para>
<para>
This function is useless in usual applications.
</para>
@menu_item: the menu item
@placement: the submenu placement
<!-- ##### FUNCTION gtk_menu_item_select ##### -->
<para>
Emits the "select" signal on the given item. Behaves exactly like
......
......@@ -495,7 +495,6 @@ This can later be composited together with other
#GtkRcStyle structures to form a #GtkStyle.
</para>
@parent_instance:
@name:
@bg_pixmap_name:
@font_desc:
......
......@@ -1372,16 +1372,6 @@ GtkWidget
@height:
<!-- ##### FUNCTION gtk_widget_get_usize ##### -->
<para>
</para>
@widget:
@width:
@height:
<!-- ##### MACRO gtk_widget_pop_visual ##### -->
<para>
......
......@@ -1097,8 +1097,7 @@ totally_invisible_line (GtkTextLayout *layout,
static void
set_para_values (GtkTextLayout *layout,
GtkTextAttributes *style,
GtkTextLineDisplay *display,
gdouble *align)
GtkTextLineDisplay *display)
{
PangoAlignment pango_align = PANGO_ALIGN_LEFT;
int layout_width;
......@@ -1129,19 +1128,6 @@ set_para_values (GtkTextLayout *layout,
break;
}
switch (pango_align)
{
case PANGO_ALIGN_LEFT:
*align = 0.0;
break;
case PANGO_ALIGN_RIGHT:
*align = 1.0;
break;
case PANGO_ALIGN_CENTER:
*align = 0.5;
break;
}
pango_layout_set_alignment (display->layout, pango_align);
pango_layout_set_spacing (display->layout,
style->pixels_inside_wrap * PANGO_SCALE);
......@@ -1670,7 +1656,6 @@ gtk_text_layout_get_line_display (GtkTextLayout *layout,
gchar *text;
PangoAttrList *attrs;
gint text_allocated, layout_byte_offset, buffer_byte_offset;
gdouble align;
PangoRectangle extents;
gboolean para_values_set = FALSE;
GSList *cursor_byte_offsets = NULL;
......@@ -1739,7 +1724,7 @@ gtk_text_layout_get_line_display (GtkTextLayout *layout,
*/
if (!para_values_set)
{
set_para_values (layout, style, display, &align);
set_para_values (layout, style, display);
para_values_set = TRUE;
}
......@@ -1908,7 +1893,7 @@ gtk_text_layout_get_line_display (GtkTextLayout *layout,
if (!para_values_set)
{
style = get_style (layout, &iter);
set_para_values (layout, style, display, &align);
set_para_values (layout, style, display);
release_style (layout, style);
}
......@@ -1955,8 +1940,6 @@ gtk_text_layout_get_line_display (GtkTextLayout *layout,
pango_layout_get_extents (display->layout, NULL, &extents);
display->x_offset += (display->total_width - PANGO_PIXELS (extents.x + extents.width)) * align;
display->width = PANGO_PIXELS (extents.width) + display->left_margin + display->right_margin;
display->height += PANGO_PIXELS (extents.height);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment