[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: Prevent gtk_label from request resize to parent
- From: Axel Simon <A Simon kent ac uk>
- To: Marcus Reis <marcus lanhelp com br>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: Prevent gtk_label from request resize to parent
- Date: Fri, 02 Dec 2005 08:25:06 +0000
On Thu, 2005-12-01 at 22:57 -0200, Marcus Reis wrote:
> hello, I have a some buttons inside a table like a matrix. Lets pick one
> of this buttons, we have one vbox set as child of the button and inside
> the box we have 4 labels. But we have a problem, one of this labels have
> a very random width, so would be desired that this specific label does
> not make requests to resize the box, or box would ignore size request
> from this child, because this is actually making the window size bigger.
> I have tried to reduce the string with string functions but the result
> is not ideal since every time we get size available, the label will not
> use it. Have tried gtk_widget_set_size_request too, but the effect is
> similar.
>
> Any lights?
If you use Gtk 2.6 or higher you can use gtk_label_set_width_chars to
set an upper bound. If you put in more characters than that, the label
should ellipsize the string, see gtk_label_set_ellipsize.
Hope this helps,
Axel.
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]