Commit graph

11 commits

Author SHA1 Message Date
Andreas Kling
8a024a3305 LibGUI: Rename GEventLoop.{cpp,h} => GWindowServerConnection
The GEventLoop class is long gone, and the only class in these files is
GWindowServerConnection, so let's update the file names. :^)
2019-11-08 11:40:25 +01:00
Andreas Kling
f1c6193d6d LibGUI: Move GTextDocument out of GTextEditor
The idea here is to decouple the document from the editor widget so you
could have multiple editors being views onto the same document.

This doesn't work yet, since the document and editor are coupled in
various ways still (including a per-line back-pointer to the editor.)
2019-10-27 16:44:16 +01:00
Andreas Kling
183f7c9830 LibGUI: Add GLazyWidget, a convenience widget for lazily-built UI's
Here's how you can use this to speed up startup time:

    auto widget = GLazyWidget::construct();
    widget->on_first_show = [](auto& self) {
        self.set_layout(...);
        ...
    };

Basically, it allows you to delay building the widget subtree until
it's shown for the first time.
2019-10-02 20:24:29 +02:00
Andreas Kling
82559e211d LibGUI: Add GModelSelection to help implementing multiple-select views
Each GAbstractView now has a GModelSelection backed by a simple
HashTable<GModelIndex>. When the selection changes somehow, the view
gets notified via the notify_selection_changed() callback.

In the future it will probably make sense to move to using some kind of
ranges as the internal representation instead.
2019-09-07 19:21:07 +02:00
Andreas Kling
5e34e43b0f LibGUI: Add GAboutDialog, a simple way to show a nice about box in apps 2019-09-02 19:45:55 +02:00
Andreas Kling
6e50631e35 LibGUI: Add GJsonArrayModel, a simple JSON-data-file-as-GModel helper
This makes it very easy to expose JSON files as GModels. :^)
2019-08-10 10:29:46 +02:00
Andreas Kling
c7ea94697e Libraries: Remove unused "install" targets.
We've been using a per-directory "install.sh" for some time, so let's get
rid of the old way of doing things.
2019-07-21 21:28:48 +02:00
Andreas Kling
1c0669f010 LibDraw: Introduce (formerly known as SharedGraphics.)
Instead of LibGUI and WindowServer building their own copies of the drawing
and graphics code, let's it in a separate LibDraw library.

This avoids building the code twice, and will encourage better separation
of concerns. :^)
2019-07-18 10:18:16 +02:00
Andreas Kling
7083a0104a LibGUI: Add GActionGroup, a way to group a bunch of GActions.
This can be used to make a bunch of actions mutually exclusive.
This patch only implements the exclusivity behavior for buttons.
2019-07-09 22:10:03 +02:00
Andreas Kling
8b0953a795 Libraries: Unbreak "make install" with new directory locations. 2019-07-04 16:41:42 +02:00
Andreas Kling
04b9dc2d30 Libraries: Create top level directory for libraries.
Things were getting a little crowded in the project root, so this patch
moves the Lib*/ directories into Libraries/.
2019-07-04 16:16:50 +02:00
Renamed from LibGUI/Makefile (Browse further)