MessageBox after SDL_Quit

On the contrary, I’d say it seems more complicated than necessary, and I
can’t even see how it could work properly. A plain blocking

SDL_ShowMessage(const char *text);

with a default “OK” button would be sufficient, IMHO.

Adding “YES/NO” and “OK/CANCEL” variants + return value would probably be
easy, but even that is stretching it, IMHO.

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------------> http://www.linuxdj.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |-------------------------------------> http://olofson.net -'On Wednesday 15 May 2002 21:28, Sami N??t?nen wrote:

On 2002.05.15 06:47 Chris wrote:

(for setting the text per error)

SDL_SetMessage(“Please e-mail the file error.log to
developer at project.com”, SDL_PARACHUTE_ERROR | SDL_UNKNOWN_ERROR);

so then, some crash would make that message to come up?

or

SDL_SetMessage(“Could not initalize video drivers.”,
SDL_VIDEO_ERROR);

for not being able to set up video?

what’s a good function prototype for this? (this one is kinda ugly)
should there be a way to flag what error message goes with which
error(s), like video init or input init?

I think there should be predefined messages in english, which just
inform what went wrong. Also the amount of different possible fatal
errors should be kept in minimum. Because this error system IMHO is not
meant for debug tool (stderr is for that), but to inform end users that
there is really big problems, and possibly tell the user where to find
more information and help. This kind of system is more than suffisient
(I mean the possibility to set the error message texts) for the purpose
it is needed.

Right. It’s just that there are too many users that don’t know where to
look, and either way, it’s not exactly what you’d expect from
applications these days.

Applications that appear to just die silently won’t exactly make Linux
newbies feel any less confused… I’m quite sure that sort of stuff is
one major reason why so many never get around to really make the switch,
even if they want to.

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------------> http://www.linuxdj.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |-------------------------------------> http://olofson.net -'On Wednesday 15 May 2002 22:41, Joseph Carter wrote:

On Wed, May 15, 2002 at 03:41:39PM +0200, Kanzelsberger Pavel wrote:

Yes you’re right, but I didn’t find any better solution to display
MessageBox in Linux (if you don’t want to link to KDE or GTK
libraries ofcourse). Maybe X-Server supports something usefull like
MessageBox in Win32 API…

It’s really not necessary for Linux because you’ve got a usable way to
read stderr, even if you start your program from some launcher like KDE
or Gnome (~/.xsession-errors or equivalent)

Sure there is - ~/.xsession-errors. =) But I have already conceded the
point that an X11 message box would be nice to have, just that it should
be implemented in bare Xt to avoid dependencies on additional libraries.On Thu, May 16, 2002 at 05:35:44AM +0200, David Olofson wrote:

In Linux, stderr is sufficient because stderr is
useful.

Problem is that it works only if you launch programs from the command
line, or explicitly tells your desktop environment to “run from
console”. For example, you won’t see any stdout output from an
application started the “normal” way under KDE or GNOME. It’s actually
worse than Win32, since there’s no standard place to look for the output
afterwards…


Joseph Carter Not many fishes

<ahzz_> i figured 17G oughta be enough.

-------------- next part --------------
A non-text attachment was scrubbed…
Name: not available
Type: application/pgp-signature
Size: 273 bytes
Desc: not available
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20020515/aba18ab9/attachment.pgp

I’m having trouble envisioning a circumstance where the SDL library is
installed and working properly, but the application is utterly unable to
init any video at all. Can someone outline when this might happen?On Thu, May 16, 2002 at 05:58:32AM +0200, David Olofson wrote:

Applications that appear to just die silently won’t exactly make Linux
newbies feel any less confused… I’m quite sure that sort of stuff is
one major reason why so many never get around to really make the switch,
even if they want to.


Matthew Miller @Matthew_Miller http://www.mattdm.org/
Boston University Linux ------> http://linux.bu.edu/

I agree, it should be simple. SDL_xxxx(const char *text); is a good
idea.On Wed, 2002-05-15 at 20:47, David Olofson wrote:

On Wednesday 15 May 2002 21:28, Sami N??t?nen wrote:

On 2002.05.15 06:47 Chris wrote:

(for setting the text per error)

SDL_SetMessage(“Please e-mail the file error.log to
developer at project.com”, SDL_PARACHUTE_ERROR | SDL_UNKNOWN_ERROR);

so then, some crash would make that message to come up?

or

SDL_SetMessage(“Could not initalize video drivers.”,
SDL_VIDEO_ERROR);

for not being able to set up video?

what’s a good function prototype for this? (this one is kinda ugly)
should there be a way to flag what error message goes with which
error(s), like video init or input init?

I think there should be predefined messages in english, which just
inform what went wrong. Also the amount of different possible fatal
errors should be kept in minimum. Because this error system IMHO is not
meant for debug tool (stderr is for that), but to inform end users that
there is really big problems, and possibly tell the user where to find
more information and help. This kind of system is more than suffisient
(I mean the possibility to set the error message texts) for the purpose
it is needed.

On the contrary, I’d say it seems more complicated than necessary, and I
can’t even see how it could work properly. A plain blocking

SDL_ShowMessage(const char *text);

with a default “OK” button would be sufficient, IMHO.

Adding “YES/NO” and “OK/CANCEL” variants + return value would probably be
easy, but even that is stretching it, IMHO.

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------------> http://www.linuxdj.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |-------------------------------------> http://olofson.net -’


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl


Chris
@Christopher_Thielen

Running from the console. Specifically, the mpeg321 program (a clone of
mpeg123 using SDL_mpeg) is capible of playing video if you run it under X.
Under the console, it plays audio-only.On Thu, May 16, 2002 at 12:19:24AM -0400, Matthew Miller wrote:

Applications that appear to just die silently won’t exactly make Linux
newbies feel any less confused… I’m quite sure that sort of stuff is
one major reason why so many never get around to really make the switch,
even if they want to.

I’m having trouble envisioning a circumstance where the SDL library is
installed and working properly, but the application is utterly unable to
init any video at all. Can someone outline when this might happen?


Joseph Carter The guy with a rocket launcher

NOTICE: anyone seen smoking will be assumed to be on fire and will be
summarily put out.

-------------- next part --------------
A non-text attachment was scrubbed…
Name: not available
Type: application/pgp-signature
Size: 273 bytes
Desc: not available
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20020515/cc6f2a34/attachment.pgp

Ok, but wouldn’t this be a circumstance in which stderr/stdout is exactly
the right response? A message box isn’t going to work either!On Wed, May 15, 2002 at 09:31:44PM -0700, Joseph Carter wrote:

Running from the console. Specifically, the mpeg321 program (a clone of
mpeg123 using SDL_mpeg) is capible of playing video if you run it under X.
Under the console, it plays audio-only.


Matthew Miller @Matthew_Miller http://www.mattdm.org/
Boston University Linux ------> http://linux.bu.edu/

Right.

However, SDL being able to set up some form of display doesn’t mean
that the application will have much use for it. (It might be an OpenGL
only application, for example.) Such an application would have to contain
specific code just to display a dialog using SDL.

Thinking about it that way, maybe the “secondary default”, next to
stdout/stderr sholud be a graphical dialog implemented on top of SDL?
(Platforms with a single standard way of generating a dialog should not
use this, of course.) This might be simpler and/or more portable than a
specific solution for X11 - although text output becomes more troublesome.

//David Olofson — Programmer, Reologica Instruments AB

.- M A I A -------------------------------------------------.
| Multimedia Application Integration Architecture |
| A Free/Open Source Plugin API for Professional Multimedia |
----------------------------> http://www.linuxdj.com/maia -' .- David Olofson -------------------------------------------. | Audio Hacker - Open Source Advocate - Singer - Songwriter |-------------------------------------> http://olofson.net -'On Thursday 16 May 2002 06:38, Matthew Miller wrote:

On Wed, May 15, 2002 at 09:31:44PM -0700, Joseph Carter wrote:

Running from the console. Specifically, the mpeg321 program (a clone
of mpeg123 using SDL_mpeg) is capible of playing video if you run it
under X. Under the console, it plays audio-only.

Ok, but wouldn’t this be a circumstance in which stderr/stdout is
exactly the right response? A message box isn’t going to work either!

Sure – a lot of SDL applications are going to need functionality similar to
that needed by other SDL apps. I’m not sure that means that all of those
things belong in SDL itself – that’s what libraries built on SDL are for,
after all.On Thu, May 16, 2002 at 07:07:14AM +0200, David Olofson wrote:

However, SDL being able to set up some form of display doesn’t mean
that the application will have much use for it. (It might be an OpenGL
only application, for example.) Such an application would have to contain
specific code just to display a dialog using SDL.


Matthew Miller @Matthew_Miller http://www.mattdm.org/
Boston University Linux ------> http://linux.bu.edu/

Applications that appear to just die silently won’t exactly make Linux
newbies feel any less confused… I’m quite sure that sort of stuff is
one major reason why so many never get around to really make the switch,
even if they want to.

I’m having trouble envisioning a circumstance where the SDL library is
installed and working properly, but the application is utterly unable to
init any video at all. Can someone outline when this might happen?

actually I’ve got an X example where the SDL-based program (SDL_gui test
"testgl" actually) fails silently on X… I still haven’t diagnosed
-why- it’s failing other than it’s not creating a display. Note that
there are -no- error messages.

note that testgl works - and for some reason my G450 isn’t initializing
OpenGL-accelerated (don’t know why, it worked up until a month ago.
Suspect Debian mucking with configurations again)

G’day, eh? :slight_smile:
- Teunis

PS: I know this is a little late reply but I think it still applies from
what I can tell…On Thu, 16 May 2002, Matthew Miller wrote:

On Thu, May 16, 2002 at 05:58:32AM +0200, David Olofson wrote: