[…]
Is there a good library out there already for doing simple pop up
message boxes. Similar to what you get in windows?
Not that I know off, but I sure could use one as well. In fact, I’d also
want a primitive console like the one Quake III: Arena and many other
games pop up when there’s no normal console available.
It has been discussed at least once before, but I don’t remember any
library showing up.
Sure, a message box it’s very trivial to code on most platforms, but just
as an example, I don’t even know the name of the function to use on Mac
OS… And I don’t know what kind of standard message boxes are available
on all platform.
How about just hacking a library up (or just a header and a source file),
so people can start using it, filling in the implementations for their
platforms? I’m going to hack and use something like it sooner or later
anyway, so I might as well maintain it, if no one else cares to do it.
First, we’ll need to come up with an API that will work for all targets,
one way or another.
For example, Win32 has a call that lets you provide a text message, a
standard icon ID, and a code specifying what buttons you want (OK, OK +
CANCEL, YES + NO etc). Is it safe to assume that most platforms can do
something similar, without custom GUI programming? If so, we could use
something like
/* SDLG for SDL (or Simple) DIaLogs */
typedef enum SDLG_Result
{
SDLG_OK,
SDLG_CANCEL,
SDLG_YES,
SDLG_NO,
SDLG_CONTINUE,
SDLG_ABORT,
SDLG_IGNORE,
} SDLG_Result;
typedef enum SDLG_Style
{
SDLG_OKBOX,
SDLG_OKCANCELBOX,
SDLG_YESNOBOX,
SDLG_CONTABORTIGN,
} SDLG_Style;
SDLG_Result SDLG_MessageBox(const char *msg, SDLG_Style style);
Comments? Code?
//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 05 December 2001 23:35, Jason Dagit wrote: