Re: Support for flexible labels under place constraints
- From: José Alburquerque <jaalburquerque gmail com>
- To: Markus Elfring <Markus Elfring web de>
- Cc: gtkmm-list gnome org
- Subject: Re: Support for flexible labels under place constraints
- Date: Tue, 04 Oct 2011 14:01:01 -0400
On Tue, 2011-10-04 at 08:30 +0200, Markus Elfring wrote:
> > No, though I don't see why it would not be possible.
> I would like to describe my use case from another perspective.
> Now I am looking for a reusable widget which deals with requirements like the
> - Ideogram
> It can be implemented as an icon (raster image/vector graphic) or as an
> Unicode character (with eventually a special font).
> - Text with varying length (abbreviation, short or full label)
> - The display should adapt to the available visual space like it is provided by
> a row/column header.
> The more space will be reduced (to an useful minimum height/width) the widget
> should only attempt to display the label part which still fits. The user can
> choose if there is a personal preference for the ideogram in combination with
> the textual description.
> - Both data components should belong to a common translation unit.
I'm sure this can be done as a custom widget using pangomm or cairomm
(or librsvgmm) to do the drawing/text rendering, etc. I've not done
anything like this myself but it doesn't sound difficult to do. There
is a chapter in the online book on custom widgets that could help in
this aspect though possibly someone else might be able to offer you
something they've done that is similar to what you're asking about:
] [Thread Prev