Commit Graph

10 Commits

Author SHA1 Message Date
Andreas Kling
3351f1ccc1 Port all apps to GApplication. 2019-02-11 14:56:23 +01:00
Andreas Kling
9483b39227 LibGUI: Add GMenu* and GApplication classes. 2019-02-11 14:43:43 +01:00
Andreas Kling
53d34a0885 Port Terminal to LibGUI.
To facilitate listening for action on arbitrary file descriptors,
I've added a GNotifier class. It's quite simple but very useful:

GNotifier notifier(fd, GNotifier::Read);
notifier.on_ready_to_read = [this] (GNotifier& fd) {
    // read from fd or whatever else you like :^)
};

The callback will get invoked by GEventLoop when select() says we
have something to read on the fd.
2019-02-10 14:28:39 +01:00
Andreas Kling
2def3d8d3f LibGUI: Start adding an automatic widget layout system.
My needs are really quite simple, so I'm just going to add what I need
as I go along. The first thing I needed was a simple box layout with
widgets being able to say whether they prefer fixed or fill for both
their vertical and horizontal sizes.

I also made a simple GStatusBar so FileManager can show how many bytes
worth of files are in the current directory.
2019-02-10 11:07:13 +01:00
Andreas Kling
e354c08c98 LibGUI: Share code for widget rendering styles in a GStyle class.
Since GScrollBar wants its internal buttons to look like GButtons,
let's share the painting code between them.
2019-02-10 07:11:01 +01:00
Andreas Kling
1f355f2a79 LibGUI: Start working on a GScrollBar.
This widget is far from finished, but it's off to a good start.
Also added a GResizeEvent and GWidget::resize_event() so that widgets
can react to being resized.
2019-02-09 11:19:38 +01:00
Andreas Kling
5158bee08c Don't use -mregparm=3 in userspace.
It's pretty comfy having arguments in registers in the kernel for now though.
2019-02-08 01:24:52 +01:00
Andreas Kling
27263b6172 Clean up LDFLAGS a bit.
While working on the ELF loader I was trying to keep binaries as simple as
possible so I could understand them easily. Now that the ELF loader is mature
and working fine, we can move closer towards ld defaults.
2019-02-06 14:48:09 +01:00
Andreas Kling
5e0b7f1a56 Add basic automatic dependency management to Makefiles. 2019-02-02 04:41:59 +01:00
Andreas Kling
b91479d9b9 Rename all the LibGUI classes to GClassName. 2019-01-20 04:49:48 +01:00