Re: input only event boxes
- From: Alexander Larsson <alexl redhat com>
- To: Owen Taylor <otaylor redhat com>
- Cc: gtk dev list <gtk-devel-list gnome org>
- Subject: Re: input only event boxes
- Date: 26 Aug 2003 22:02:46 +0200
On Tue, 2003-08-26 at 17:57, Owen Taylor wrote:
> The main API issue that came to mind is that input-only event boxes
> are different from normal event boxes along two different axes:
>
> A) They aren't visible
> B) They trap events to the child before they get to the child.
>
> While for a non-selectable label or image, B) isn't relevant, it might
> be relevant in some other uses - say, trying to put a tooltip on
> a container with multiple buttons in it.
>
> So, I wonder if we should offer separate properties:
>
> "input-only"
> "above-child"
>
> We can implement all four combinations pretty easily with one
> non-obvious trap for input-only, !above-child: since the input
> window isn't a parent window of the child, if the child window
> doesn't have an event in it's event mask, it won't be received.
This sounds pretty good to me. At least input-only, !above-child is
useful. I dunno if !input-only, above-child makes much sense though? How
can the parent window be above its children?
Maybe a three value enum with: input-output, input-only+above-child and
input-only+!above chile makes more sense?
> The other API issue is that the term input-only is a negative, so
> when you start writing "not input-only" in the docs, it looks rather
> weird.
>
> Would "visible-window" (default TRUE) be a better name than
> "input-only"?
I used input-only because it is a well known (ehrm, well...) term in
gdk. Maybe we should remove the input-only name from the whole api and
give it a more descriptive name like visible-window, yeah.
> "An event box with a visible window" "An event box without a visible
> window" reads a lot better than "An input-only event box"
> "A not input-only event box".
>
> Some detailed comments, not all completely relevant if we add something
> like "above_child".
>
> +typedef struct
> +{
> + gboolean input_only;
>
> I think it's confusing that you use this flag in a couple of places
> and GTK_WIDGET_NO_WINDOW() everywhere else. (I assume the usage
> of GTK_WIDGET_NO_WINDOW() is to avoid having to get the priv structure.)
>
> You might just want to use NO_WINDOW() everywhere.
Yeah. I dunno why I added the flag.
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Alexander Larsson Red Hat, Inc
alexl redhat com alla lysator liu se
He's an unconventional guerilla vagrant in a wheelchair. She's a wealthy
impetuous lawyer with an MBA from Harvard. They fight crime!
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]