Commit Graph

115 Commits

Author SHA1 Message Date
Tom Gilbert ded180a361 Thu Dec 02 23:07:45 GMT 1999
(gilbertt)

Ok. More config window stuff.

Fun fun. I had to create a new type, Epplet_window to hold some window info,
and a stack to push and pop contexts for adding gadgets to different new
windows. This stuff works real well, and I am chuffed with it :)

The extra windows now redraw themselves on exposes, and new gadgets can be
added to them successfully. W00p.

I had to implement some new stuff, so please check nothing is broke (I am
not finished, but I don't want to commit code that breaks stuff).

Here are some details on the new stuff :)

---------------
PUBLIC STUFF

typedef struct epplet_window
{
    Window win;
    int w;
    int h;
    Pixmap bg_pmap;
    Pixmap bg_mask;
    Pixmap bg_bg;
}EppWindow;
typedef EppWindow *Epplet_window;

Epplet_window Epplet_create_window(int w,int h,int x,int y,char *title);
void Epplet_window_show(Epplet_window win);
void Epplet_window_hide(Epplet_window win);
void Epplet_window_destroy(Epplet_window win);
void Epplet_window_push_context(Epplet_window newwin);
Epplet_window Epplet_window_pop_context(void);
---------------
PRIVATE STUFF

static Epplet_window context_win;       /* Current context win */
static int          window_stack_pos;   /* For context changes */
static Epplet_window window_stack[20];  /* For context changes */
static Epplet_window mainwin;           /* Always the main epplet window */

static int          window_num = 0;     /* For window list */
static Epplet_window *windows = NULL;   /* List of windows to loop though */

/* For Keeping a list of windows owned by the epplet, to loop through and
 * do stuff with. */
static void         Epplet_register_window(Epplet_window win);
static void         Epplet_unregister_window(Epplet_window win);

/* Redraw all epplet windows (excluding the main epplet window) */
static void         Epplet_draw_windows(void);
/* Redraw window win */
static void         Epplet_draw_window(Epplet_window win);

/* Refresh window backgrounds on theme change */
static void Epplet_refresh_backgrounds(void);

-------------
I also added an item to GadGeneral so that I can find what window a gadget
was created on:

typedef struct gad_general
{
   GadType             type;
   char                visible;
   Epplet_window       parent;
}
GadGeneral;

-------------

Not to mention the reworking of code which draws or handles windows.

I have more tinkering to do in the event handling, to catch delete_events,
and to filter out mouseovers etc for separate windows. Tomorrow :)


SVN revision: 1478
1999-12-02 19:08:48 +00:00
Michael Jennings 664df20d8c Wed Dec 1 19:11:13 PST 1999
(KainX)

For one thing, I think I've fixed the seg fault in E-MoonClock.  Here's
hoping.

I also added the background setting functionality to E-Slides, but this time
it was done *right*. :-)  Take a look and see for yourself.  If you look at
the code, it also demonstrates how to use E IPC to set backgrounds.


SVN revision: 1476
1999-12-01 23:09:48 +00:00
Tom Gilbert 4d1ca43a00 Wed Dec 01 23:05:13 GMT 1999
(gilbertt)

api changes.

Ok. I have added some functions to the api, they are not yet perfect, but
they compile cleanly and don't create any problems. Don't use them yet
though, the api may change.

Window Epplet_create_window(int w,int h,int x,int y,char *title);
void Epplet_window_show(Window win);
void Epplet_window_hide(Window win);
void Epplet_window_destroy(Window win);
void Epplet_window_switch_context(Window newwin);
void Epplet_window_reset_context(void);

All of these functions are in place and work. I have yet to add code to
handle delete_events. At the moment, if you close the dialog window, the
epplet exits. This is clearly not intended ;) I'll fix it tomorrow, its late
here now.

You can even switch context and add widgets to your new window with no
problems ;)

Other things to fix tomorrow is the event handling stuff which assumes only
one window will be around...

I am currently using E-ScreenSave as my test epplet for this code, as I know
only about 2 people use it ;) Try it to see the code working.


SVN revision: 1472
1999-12-01 19:12:33 +00:00
Tom Gilbert 9ce2ad30c3 Tue Nov 30 17:48:31 GMT 1999
(gilbertt)

E-ScreenShoot.c E-SD.c E-ScreenSave.c

Urm. Should've done this before. Removed some duplication, and one omission
in my cloaking code. Silly really, most people won't notice any difference,
but I will :)


SVN revision: 1462
1999-11-30 14:45:32 +00:00
Michael Jennings 3e6a527f10 Mon Nov 29 20:34:40 PST 1999
(KainX)

All the network stats stuff has been moved to a centralized location, and all
the network stats epplets have been converted to use the new functions.  Thus,
all network epplets can now have a portable interface to the data without
having to worry about portability; the backend takes care of it.

I also added copyright statements and a license to all my epplets.  And I
removed my name from the E-Mountbox copyright since my contributions were
negligible. :-)


SVN revision: 1460
1999-11-30 00:52:31 +00:00
Michael Jennings 8ab0c9d1cf Mon Nov 29 19:03:00 PST 1999
(KainX)

Applied and modified significantly a patch to support E-NetFlame on Solaris.
Thanks to Tomas Calvo Gomez <tcalvo@tid.es> and Mark Bowyer
<Moredhel@earthling.net> for supplying the Solaris-isms. :-)


SVN revision: 1458
1999-11-29 23:21:26 +00:00
Michael Jennings c62780f399 Mon Nov 29 17:08:23 PST 1999
(KainX)

This fixes the bug E-Slides demonstrated in the focus stuff.  Doesn't seem to
break anything else as far as I can tell....


SVN revision: 1456
1999-11-29 21:25:54 +00:00
Michael Jennings 8e16291969 Mon Nov 29 16:03:53 PST 1999
(KainX)

Added support for specifying the width and height (in epplet units, 16 pixels)
of the E-Slides window.  -w <width> and -h <height> are the options.  The
default is the traditional 3x3, of course.  Note that this cannot be done via
config file options since the size is set before the config loader can be
called.


SVN revision: 1455
1999-11-29 20:23:05 +00:00
Tom Gilbert 6680bc8f5d Mon Nov 29 14:08:10 GMT 1999
(gilbertt)

Tidied up E-UrlWatch lots. Its pretty lean now.


SVN revision: 1451
1999-11-29 10:29:22 +00:00
Richard Barnes 10af2854ff More fun with focus...
SVN revision: 1450
1999-11-28 22:59:25 +00:00
Richard Barnes 1a79294f41 Change to something more like ClickToFocus. The gadgets won't *keep* the focus
unless you click them. This probably needs a little more work...


SVN revision: 1449
1999-11-28 22:33:31 +00:00
Richard Barnes c588207445 Make focusing between an epplet and it's gadget's work a little better. Basically added sloppy-focus. The epplet remembers which gadget last had focus and, if none currently have focus and the last_gadget was a textboxes, passes key events to it.
SVN revision: 1448
1999-11-28 22:08:49 +00:00
Tom Gilbert 517bc09e71 Mon Nov 29 01:08:58 GMT 1999
(gilbertt)

Hrm. A segfault with a certain form of url. Fixed.


SVN revision: 1446
1999-11-28 21:31:57 +00:00
Tom Gilbert ba3c47ab02 forgot this
SVN revision: 1431
1999-11-28 18:17:44 +00:00
Tom Gilbert b0d77efe53 Sun Nov 28 21:06:21 GMT 1999
(gilbertt)

Added a popup containing a history of the urls you launch, of the urls found
in the file being watched. This is cool :)


SVN revision: 1428
1999-11-28 17:31:59 +00:00
Tom Gilbert 6508a63aa4 Sun Nov 28 20:04:45 GMT 1999
(gilbertt)

Fixed some overzealous free()ing (no checks) in Epplet_gadget_destroy()


SVN revision: 1426
1999-11-28 16:31:23 +00:00
Tom Gilbert b732ee2c88 Sun Nov 28 01:12:11 GMT 1999
(gilbertt)

Added some help dox for E-UrlWatch.


SVN revision: 1421
1999-11-27 21:45:32 +00:00
Richard Barnes 7194de932b Textbox bugfixes (I hope), thanks for bitching, guys *ducks*
SVN revision: 1418
1999-11-27 17:58:33 +00:00
Richard Barnes 962a738516 You can paste to textboxes now....whoopty d00.
SVN revision: 1417
1999-11-27 16:17:16 +00:00
Tom Gilbert 921c8df941 Sat Nov 26 00:48:19 GMT 1999
(gilbertt)

Added a groovy new noise for E-UrlWatch to make when a new URL is found.
Coolness. Now supports TE ootb.


SVN revision: 1414
1999-11-26 21:34:02 +00:00
Tom Gilbert 92ecfe4aad Fri Nov 25 19:17:05 GMT 1999
(gilbertt)

E-UrlWatch

Added support for URL grabbers such as that found in TE/Epic. In the example
of TE, urls are stripped from irc convo, and dumped into ~/.te/.urls
If told to via the config (as it will by default), E-UrlWatch will watch
that file, and will strip out new urls and allow you to view them at the
touch of a button. (Or automatically if you specify). It'll also perform a
configurable command (I use it to play a sound) when a new URL appears.

Other misc cleanups have taken place, and I have very carefully hidden a
couple of juicy bugs. Find them for me, and you win a prize ;)


SVN revision: 1409
1999-11-26 16:08:48 +00:00
Tom Gilbert 014e7ab5cc Thu Nov 25 20:48:51 GMT 1999
(gilbertt)

Oops. Fixed a naughty segfault with my shoddy string handling routines.


SVN revision: 1402
1999-11-25 17:42:17 +00:00
Michael Jennings 89085f3eee Wed Nov 24 18:33:45 PST 1999
(KainX)

Major restructuring and cleanup.  I think the new standard should be pretty
self-explanatory, but let me know if you have any questions.  CVS developers,
PLEASE read epplets/Makefile.am carefully to see how it all works now.

Icons are stored in epplets/icons/ and are installed into
$EROOT/epplet_icons/.  All miscellaneous data files (including images) are
stored in epplets/<epplet name>-data/ and are installed into
$EROOT/epplet_data/<epplet name>/.  Also note that, if you're going to use the
same old aircut3.ttf and bg.png in your help section, add your epplet's name
to NEED_BG and NEED_FONT in epplets/Makefile.am.  Do NOT commit duplicates of
those two files.


SVN revision: 1394
1999-11-24 23:36:51 +00:00
Michael Jennings 715f7a2a62 Wed Nov 24 12:11:04 PST 1999
(KainX)

Added checks for epplet image classes on startup.  Adapted from a patch by
Troy Pesola <troy.pesola@network.com>.


SVN revision: 1392
1999-11-24 17:16:39 +00:00
Tom Gilbert b00a41b4e9 Wed Nov 24 20:11:57 GMT 1999
(gilbertt)

E-UrlWatch.

Now displays the url it launches, and scrolls long urls back and forth, so
you can see 'em.


SVN revision: 1391
1999-11-24 17:13:47 +00:00
Tom Gilbert a5df9b1bdb Whoops.
SVN revision: 1390
1999-11-24 15:36:59 +00:00
Tom Gilbert e73575f1d3 Tue Nov 23 23:26:47 GMT 1999
(gilbertt)

Now save all urls processed to ~/.Urls

Auto e-mailing to your mom is not yet supported.


SVN revision: 1385
1999-11-23 20:39:49 +00:00
Tom Gilbert c74483a8fd Tue Nov 23 22:30:44 GMT 1999
(gilbertt)

Whee! Say hello to E-UrlWatch.epplet.

This is a url-launcher, which will do a few cool things. Currently, it
launches urls using the X paste buffer. The idea is that you are on irc, or
reading an email, and see a url, you select the text, press the "Paste"
button on the epplet, and the url is launched. The command to launch the
url is defined in the config.

The epplet will parse the text, so you can grab a load of text, and it'll
find and launch the embedded url.

It'll also clean up naughty chars, but I have more to do here.

The next step is the "watching" part. The epplet will watch a text file (or
several) containing a list of urls, and will flash when a new one is added.
Clicking the (not yet existing) launch button will launch this url. The idea
is for apps like TE which use a url list ~/.te/.urls. So you're in irc,
someone gives you a url, and the epplet flashes and lets you launch it, no
typing.

Also, (once I code it), the epplet will record all urls you launch through
it in a text file. In a later version, this list will be emailed to your mom
on a weekly basis
;)

Obviously, this thing has the cloaking stuff, as I just copy and paste it
these days :)

Its an early beta, so bear with me while I rapidly add features :)


SVN revision: 1382
1999-11-23 19:52:17 +00:00
Tom Gilbert 112d70f585 Tue Nov 23 21:32:21 GMT 1999
(gilbertt)

I am such a dufus.

Changed my epplets to actually save their config when you finish your X
session, instead of only when you click the close button.

How did I let this go unfixed???


SVN revision: 1381
1999-11-23 18:51:27 +00:00
Michael Jennings a7ce9b2707 Tue Nov 23 11:03:39 PST 1999
(KainX)

Fixed a seg fault bug in E-Slides.


SVN revision: 1372
1999-11-23 16:19:42 +00:00
Richard Barnes 2abef1bc16 Added an option to E-Slides config to change root bg when image changes.
SVN revision: 1363
1999-11-22 04:18:43 +00:00
Richard Barnes 910865b613 Added a button to set the bg to the current E-Slides pic
SVN revision: 1360
1999-11-22 01:44:12 +00:00
Tom Gilbert 5fa60f011f need this
SVN revision: 1357
1999-11-20 22:25:11 +00:00
Richard Barnes 1e7b2e44e9 Added a popup command history to E-Exec and made it wider.
SVN revision: 1355
1999-11-20 20:56:12 +00:00
Tom Gilbert e37a5b5f7b Floop.
SVN revision: 1353
1999-11-20 19:52:34 +00:00
Richard Barnes ba9e68c662 Still E-MoonClock
SVN revision: 1348
1999-11-20 19:29:14 +00:00
Richard Barnes 5874ebe35e Update debian/rules to put stuff in epplet_data.
SVN revision: 1346
1999-11-20 19:13:39 +00:00
Tom Gilbert 87448696d2 Sat Nov 20 19:55:22 GMT 1999
(gilbertt)

Changed the Makefile.am to put epplet images in $EROOT/epplet_data.

I wanted to have epplet subdirs under this directory, but it really
complicated the Makefile, so I left it for now. It was easy for me the make
the changes with sed this way too ;)

Any stuff your app needs to install should go in epplet_data, preferably
with the filename prefixed with the name of your epplet.

Flame me if this bugs you...


SVN revision: 1345
1999-11-20 17:55:56 +00:00
Michael Jennings 4d54be14f9 Fri Nov 19 17:49:09 PST 1999
(KainX)

Fixes and cleanups to E-NetGraph.  It now does config files properly and
includes all the options in them.


SVN revision: 1340
1999-11-19 23:56:08 +00:00
Michael Jennings cfe314b476 Fri Nov 19 12:35:48 PST 1999
(KainX)

Okay, all the conditional build stuff should be fixed up now.  I'll need some
SGI people to test this as well as Solaris people, since it's entirely
possible I borked them both. :-)


SVN revision: 1336
1999-11-19 18:46:24 +00:00
Tom Gilbert 50a526a8ad whoops
SVN revision: 1332
1999-11-18 18:05:05 +00:00
Tom Gilbert 806f36865a Thu Nov 18 19:15:14 GMT 1999
(gilbertt)

Changes to E-NetGraph.c

Removed some warnings which show up when compiling with -Wall.


SVN revision: 1331
1999-11-18 18:04:30 +00:00
Tom Gilbert 8ff8586bd2 Thu Nov 18 19:15:14 GMT 1999
(gilbertt)

Changes to E-ScreenShoot

Added a couple of new config options. They're in the dox, but I'll yip about
them too.

VIEW_SHOT & VIEWER   -   View shot after taking it using VIEWER (ee default)
RUN_SCRIPT & SCRIPT_TO_RUN  -  Run script/program after taking shot, sending
filename as parameter.

Also cleaned up some of that code, it was hairy.


SVN revision: 1329
1999-11-18 17:55:21 +00:00
Tom Gilbert 5b1e03039a Thu Nov 18 18:42:45 GMT 1999
(gilbertt)

Changes to cloak.[ch]

If those functions are not going to be static any more, declare them in
cloak.h, so other epplets can use them


SVN revision: 1328
1999-11-18 17:08:12 +00:00
Tom Gilbert 30f5ffa096 Thu Nov 18 18:16:12 GMT 1999
(gilbertt)

Working towards cool new E-ScreenShoot features.

They're not there yet though :)


SVN revision: 1327
1999-11-18 16:41:37 +00:00
Richard Barnes dd5ea78699 Ok, added the *real* E-NetGraph to cvs. Coded by Daniel Erat
(http://www2.ucsc.edu/~erat/). I had no idea this existed, it rocks. It takes
hella command-line options, but I modified it to use a config file too. It may
not run at first if your net device is not ppp0 and you don't specify. This
will be changed.


SVN revision: 1326
1999-11-18 15:27:22 +00:00
Richard Barnes f2fa15235c Made most of the functions in epplets/cloak.c non-static so that they can be
accessed by other epplets. Also Added E-NetGraph, a wmnet wannabe epplet.


SVN revision: 1325
1999-11-18 01:35:21 +00:00
Michael Jennings 00c98e327a Wed Nov 17 14:18:42 PST 1999
(KainX)

Cleanups to the libgtop stuff.  Someone (Mark) please tell me if this doesn't
work on Solaris....


SVN revision: 1322
1999-11-17 20:55:49 +00:00
Richard Barnes 9e0f00c611 Tue Nov 16 17:10:44 EST 1999
(StriderZ)

Added a textbox cursor.


SVN revision: 1318
1999-11-16 21:02:11 +00:00
Michael Jennings 5ae5797f94 Mon Nov 15 12:30:13 PST 1999
(KainX)

Another morning, another cleanup.  Doesn't anyone use warning flags besides
me?


SVN revision: 1313
1999-11-15 19:37:56 +00:00