Index: [thread] [date] [subject] [author]
  From: Marcus Sundberg <mackan@stacken.kth.se>
  To  : ggi-develop@eskimo.com
  Date: Mon, 19 Jul 1999 20:29:33 +0000

Re: Patch for disabling ggi messing with X's cursor

Osku Salerma wrote:
> But the point is that my application uses the graphical window just as
> a _bonus_ representation of some data, and the real program runs in
> the text-console (xterm or whatever), and you can disable the graphics
> altogether if you want with a command line switch. You _can't_ even
> think about running the program in targets that only support
> full-screen modes. 

Sure you can. There are multihead systems, serial consoles, and
telnet connections. This is exactly the flexibility LibGGI tries to
make applications conform to.

> I don't see why every single ggi application should do its own
> cursor-handling if there is a very simple way of telling ggi "don't mess
> with the cursor, I'm happy with the default one".

Even though LibGGI apps will run fine in an X window LibGGI is primarily
a fullscreen graphics library, and this is reflected in the API.
>From the application's point of view the X window is the "full" screen.

> I do agree that having "-defcursor" type flags around can seem a
> little klunky. Perhaps a more preferable approach would be something
> like:
> 
> ggiAddFlags(vis, GGI_DONT_CHANGE_CURSOR);
> 
> That would be portable across all targets, and is cleaner I agree. I
> just thought of this and haven't looked at how hard it would be to
> implement, so before I do, could you comment if I should bother or
> does this one have no chance of getting in either?

The correct way to do this is to add a "default cursor" to the 
cursor extension, which will use the native cursor appearance when
running in a window.

> GGI is such a great library to use for all my graphics needs that it'd
> be a shame if we can't agree on a way to let me have X's own cursor
> over ggi-windows. That's hardly an unreasonable thing to ask, now is
> it? Especially since it isn't even code bloat, it's the opposite
> actually..

The reason I'm against this hack is that if people see that there
already is a cursor they will not properly implement support for
the application to run on any target. Programmers are lazy, and no
docs or guidlines in the world are going to change that.

We have taken very good care to ensure that all system dependent
weirdnesses are hidden behind a simple to use API, and to simplify
things for the application programmer whereever we can. But in doing
this we never sacrifice ease of use and flexibility for the end user.

//Marcus
-- 
-------------------------------+------------------------------------
        Marcus Sundberg        | http://www.stacken.kth.se/~mackan/
 Royal Institute of Technology |       Phone: +46 707 295404
       Stockholm, Sweden       |   E-Mail: mackan@stacken.kth.se


Index: [thread] [date] [subject] [author]