Commit graph

33 commits

Author SHA1 Message Date
Bill Currie
1c13339bbe [qwaq] Create a type encoding class
For now it just manages type encodings via their encoding string,
ensuring types are fetched from the target only once, if at all (may
already have the type due to it being common).
2020-03-30 12:43:02 +09:00
Bill Currie
6ff5b5c101 [qwaq] Clean up the qwaq directory
Things were getting rather cluttered with everything being qwaq-* and
all in one directory. Now most have lost the qwaq- prefix and have been
moved into subdirectories (non-recursive make).
2020-03-30 02:34:08 +09:00
Bill Currie
115541877a [qwaq] Set up an application color palette
Nothing special, just all the combinations of the 8 colors
2020-03-26 09:01:39 +09:00
Bill Currie
0d8815f274 [qwaq] Handle debug events at the app level
The debugger displays the source file but doesn't highlight the current
line yet.
2020-03-25 01:32:52 +09:00
Bill Currie
e69c430abc [qwaq] Clean up QwaqApplication
It doesn't need to be fun little tests any more.
2020-03-25 01:06:20 +09:00
Bill Currie
e56d00f27f [qwaq] Make qwaq_message_t more useful
Couldn't use @param because of its use in gcc as well as qfcc.
2020-03-24 19:52:00 +09:00
Bill Currie
995074269b [qwaq] Handle some keys in the editor
Doesn't work yet, though.
2020-03-24 13:38:20 +09:00
Bill Currie
77651dbcba [qwaq] Implement focus handling
Sort of works (when not segfaulting due to problem fixed in next
commit).
2020-03-24 13:33:28 +09:00
Bill Currie
8b193c6b6c [qwaq] Remove some debug prints 2020-03-23 22:28:18 +09:00
Bill Currie
9bc91cd7d1 [qwaq] Implement resizing
Terminal resize is detected and the views adjust appropriately (well,
those for which I've set grow flags: the window title bar doesn't adjust
yet).
2020-03-23 20:14:32 +09:00
Bill Currie
10adb116ef [qwaq] Start working on the source view/editor
Line formatting is a bit messed up, but other than non-virtual text
being double-counted, things seem to be ok (view only).
2020-03-22 22:03:34 +09:00
Bill Currie
50290baf04 [qwaq] Add missing part of commit 2020-03-22 13:54:54 +09:00
Bill Currie
65538104bf [qwaq] Tweak listener message names
I didn't like the message:message bit
2020-03-19 23:18:01 +09:00
Bill Currie
e8d947ed8a [qwaq] Get click and drag reporting working 2020-03-19 19:25:57 +09:00
Bill Currie
95d20d67c7 [qwaq] Implement mouse grabbing
Button will need it for dragging.
2020-03-19 19:00:03 +09:00
Bill Currie
2c20a031e4 [qwaq] Do up a little button test "scene"
Hmm... "scene"... too much Unity?
2020-03-19 18:41:53 +09:00
Bill Currie
19161ea80a [qwaq] Clean things up in prep for button testing 2020-03-19 16:27:30 +09:00
Bill Currie
2f3ca9d9e4 [qwaq] Clean up the hierarchy
I think I've finally figured out what I want the core hierarchy to be.
Right now, it's just the two classes: View and Window (derived from
View). Window has a Group, and Group is just a collection of Views that
it manages. QwaqApplication is just an object but like a Window, it has
a Group of views.

    View
      Window has a Group
    Group contains Views
    QwaqApplication has a group

More work needs to be done on drawing and event handling, but things are
working again.
2020-03-19 11:32:44 +09:00
Bill Currie
affadc3d25 [qwaq] Create protocols for DrawBuffer and TextContext
Plenty of flaws at the moment (casts to id :/), but the basic idea seems
to be ok.
2020-03-18 01:40:41 +09:00
Bill Currie
877ad35a82 [qwaq] Rework the hierarchy again
It doesn't work right now because View unconditionally sends refresh to
its textContext, but textContext can be a draw buffer which does not
respond to refresh. Still, these changes (notably the assignment chain
in qwaq-group.r really pushed qfcc).
2020-03-14 19:45:07 +09:00
Bill Currie
d0f21ec2b4 [qwaq] Add -refresh to TextContext
This does the right thing in the presence of panels and dealing with
stdscr.
2020-03-13 03:09:42 +09:00
Bill Currie
ba9c43d2d3 [qwaq] Create a TextContext class
It is essentially just a wrapper around the window versions of ncurses
functions.
2020-03-06 13:54:46 +09:00
Bill Currie
ad4cde15b5 [qwaq] Get Window working
It even draws a border around itself.
2020-03-06 00:32:09 +09:00
Bill Currie
f18e3c3ad7 [qwaq] Add wborder command 2020-03-06 00:31:29 +09:00
Bill Currie
c377b324a1 [qwaq] Add Group and clean up lots of mess
Things are finally doing something again, and getting closer to having a
moveable window.
2020-03-05 15:44:53 +09:00
Bill Currie
f3236410d0 [qwaq] Make the event system more informative
Doesn't have timestamps at this stage, but otherwise it reflects the
event system I had in my old text UI which was heavily based on
TurboVision. TV is pretty good (after looking at things a bit closer I
found it wasn't as deep as I thought), and better yet, Borland released
it to the public domain 23 years ago! (wish I'd known that).

Anyway, this commit gets something happening on the screen, even though
the current hierarchy is still a mess.
2020-03-04 22:09:40 +09:00
Bill Currie
d57e05258c [qwaq] Remove now unnecessary union field name
\o/
2020-03-04 19:10:09 +09:00
Bill Currie
c58cf2c2d0 [qwaq] Fail at object oriented design 101
This is horrible, doesn't work, isn't really the direction I want to go
(that became apparent while implementing Screen's handleEvent) and
crashes anyway (Array and not-id...)

*sigh*

Still, this does have some good stuff in it, and it pushed qfcc along
some more.
2020-03-03 21:32:19 +09:00
Bill Currie
d91289ea1b [qwaq] Remove unnecessary wrefresh calls 2020-03-02 18:43:27 +09:00
Bill Currie
6f1386fa0d [qwaq] Test out acs chars and the classes
Crashes due to flooding the command buffer, but otherwise works (with
larger buffer).
2020-03-02 18:29:31 +09:00
Bill Currie
b9ab30ff59 [qwaq] Add mvwaddch and ACS support 2020-03-02 18:27:08 +09:00
Bill Currie
92cb3a5285 [qwaq] Flatten the hierarchy and do some cleanup 2020-03-01 18:25:02 +09:00
Bill Currie
df2ed4b086 [qwaq] Move from tools to ruamoko
This fixes the dependency issues between qwaq and ruamoko. qwaq is
actually older than ruamoko. That little language feature test has come
a long way.

However, I'm considering moving to non-recursive make, but...
2020-03-01 00:55:15 +09:00
Renamed from tools/qwaq/qwaq-app.r (Browse further)