distance in pixels between 2 GtkTextIters
- From: "Nick Gravgaard" <me nickgravgaard com>
- To: gtk-i18n-list gnome org
- Subject: distance in pixels between 2 GtkTextIters
- Date: Fri, 7 Sep 2007 11:14:58 +0200
Hi,
I'm trying to figure out how to get the distance in pixels between 2
GtkTextIters. At the moment I'm using gtk_text_iter_get_slice() to get
a char pointer, and then using gtk_widget_create_pango_layout() and
getting the width from that using pango_layout_get_pixel_size(). The
problem with this approach is that it doesn't take into account any
bold and/or italic text that might occur between the 2 GtkTextIters.
What's the solution to this problem?
Thanks,
Nick
PS. This was originally posted to gtk-app-devel-list, but I'm
reposting it here as it may be more of a Pango question.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]