Re: GtkCanvas requirements?



On Qui, 2007-04-19 at 15:00 -0400, Havoc Pennington wrote:
> Hi,
> 
> Carlos Garnacho wrote:
> > First of all we need to specify the feature requirements for the  
> > canvas.
> 
> I'd step back first and do use-cases instead, and also talk about at a 
> high level what the canvas is for and when it would be used, i.e.:
> 
>   - when is a canvas item used vs. a widget? what current widgets would
>     be "replicated" as canvas items?
>   - when is a canvas used vs. just drawing to a drawable with Cairo and
>     Pango?
>   - is the canvas essentially a fixed-up replacement for
>     GtkWidget/GtkContainer (the GTK widget core) or does it have some
>     other purpose? If it has another purpose, what is it?
>   - can a list of use cases be spelled out?
>   - how are existing canvases being used? which apps seem to be
>     using canvases and why and for what?

  I can tell you the reasons why I usually use a canvas:

	1. Writing widgets is _very hard_ (when compared to e.g. canvas items).

	2. Dynamically creating tons of widgets is costly, or at least I get
that impression, due to round-trips when creating gdk windows, or gdk
contexts, or whatever;

	3. The Gtk widget size negotiation protocol is not flexible enough;

	4. Widgets cannot be printed to a PDF file or printer while preserving
full vectorial information (and no, taking a pixmap of a window and
printing that is certainly not good enough for quality publishing);

	5. Overlaying widgets and making translucent widgets is difficult or
impossible;

	6. I want to make slightly interactive diagrams with a clearly
distinctive style from regular gtk widgets, namely i want to draw math
plots for later export into articles.  For this kind of content, users
don't want their selection of gtk theme to interfere with final content,
and the content should have white background and simple colors, none of
these gradients and 3d look that widgets have.

  These are my reasons.  I will not comment on whether or not the gtk
widget system could fulfill my needs.

-- 
Gustavo J. A. M. Carneiro
<gjc inescporto pt> <gustavo users sourceforge net>
The universe is always one step beyond logic




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]