Andreas Kling
2cebf78fad
GTextEditor: Add assertion that did_change() isn't called in readonly mode.
2019-06-23 08:23:37 +02:00
Andreas Kling
6a0011dcea
LibGUI+VisualBuilder: Support custom editing widgets for property values.
...
Implemented this by letting GAbstractViews provide a GModelEditingDelegate
for a given index, which then knows how to create and setup a custom widget
appropriate for the data type being edited.
2019-06-23 08:18:28 +02:00
Andreas Kling
1d0ada32cc
GComboBox: Add set_text() and on_return_pressed hook.
...
Also give focus back to the editor when closing the list popup window.
2019-06-23 07:55:28 +02:00
Andreas Kling
0af61e9123
GVariant: Add to_string(GVariant::Type) helper.
2019-06-23 07:54:46 +02:00
Andreas Kling
0e18201b7e
GTextEditor: Don't replace selection on enter press in single-line editor.
2019-06-23 07:53:58 +02:00
Andreas Kling
3e7f33e4eb
GAbstractView: Correct placement of editor widgets.
2019-06-23 06:45:23 +02:00
Andreas Kling
3f0f7caa45
LibGUI: Fix compiler warnings.
2019-06-22 14:41:11 +02:00
Andreas Kling
41613e4303
GSpinBox: Make the increment/decrement buttons unfocusable.
2019-06-22 11:16:41 +02:00
Andreas Kling
ff321d53ef
GComboBox: Don't make the list window wider than the widget unless needed.
2019-06-22 10:50:58 +02:00
Andreas Kling
7d17689e17
LibGUI: Add a new GComboBox widget.
...
This widget combines a GTextEditor, a GButton, a GWindow and a GListView
to implement a nice drop-down list.
It's currently using the GWindowType::Tooltip type because that's the most
appropriately behaving window type available at the moment. This should
definitely be fixed though.
2019-06-22 10:47:29 +02:00
Andreas Kling
d0b7d5e84c
GAbstractView: Add on_selection callback.
...
This callback is fired whenever the model's selection is updated.
Note that it only fires when there is a model, and when the index is valid.
2019-06-22 10:40:35 +02:00
Andreas Kling
dd6b8135c2
GScrollableWidget: Make the scrollbar metrics helpers public.
2019-06-22 10:39:42 +02:00
Andreas Kling
de4d85b097
GButton: Make it possible to disable focusability.
2019-06-22 10:39:13 +02:00
Andreas Kling
c31cf907ce
GTextEditor: Add select_all() API.
...
Take the implementation of Ctrl+A and expose it as an API for clients.
2019-06-22 10:38:38 +02:00
Andreas Kling
9ee63ef8b3
GVariant: Add a constructor that takes const char*.
...
This prevents the compiler from selecting the GVariant(bool) constructor
which is clearly not what I want when I do GVariant("Hello"). :^)
2019-06-22 10:37:44 +02:00
Andreas Kling
e9cbda29e9
GWindow: Make destroy-on-close an optional behavior.
...
Also add missing implementation of GWindow::is_visible().
2019-06-22 10:37:03 +02:00
Andreas Kling
d343fb2429
AK: Rename Retainable.h => RefCounted.h.
2019-06-21 18:58:45 +02:00
Andreas Kling
550b0b062b
AK: Rename RetainPtr.h => RefPtr.h, Retained.h => NonnullRefPtr.h.
2019-06-21 18:45:59 +02:00
Andreas Kling
90b1354688
AK: Rename RetainPtr => RefPtr and Retained => NonnullRefPtr.
2019-06-21 18:37:47 +02:00
Andreas Kling
77b9fa89dd
AK: Rename Retainable => RefCounted.
...
(And various related renames that go along with it.)
2019-06-21 15:30:03 +02:00
Andreas Kling
da475ce3f5
LibGUI: Refactor the keyboard activation code a bit to use WeakPtr<GWidget>.
2019-06-21 10:09:57 +02:00
Andreas Kling
940eb1bbeb
Merge pull request #173 from faissaloo/serenity-keys
...
SerenityKeys
2019-06-16 22:37:33 +02:00
faissaloo
54005e6942
GWindow: Get rid of superflous variable
2019-06-16 21:07:55 +01:00
faissaloo
55e115b0cd
LibGUI: clang-format
2019-06-16 21:01:51 +01:00
faissaloo
770907f90c
GWindow: Cleanup
2019-06-16 16:55:39 +01:00
Andreas Kling
1db169244a
GSpinBox: The initial text should be "0".
2019-06-16 15:08:52 +02:00
faissaloo
b635c3db54
Merge remote-tracking branch 'origin/master' into serenity-keys
2019-06-15 21:55:17 +01:00
faissaloo
50fd9ed383
GWindow: Hide SerenityKeys when window is deselected
2019-06-15 21:53:25 +01:00
Andreas Kling
d7756fc09f
LibGUI: Add an "exclusive" property to GAbstractButtons.
...
This makes checkable buttons exclusive with other checkable buttons in the
same parent widget. Basically like radio buttons. This should probably be
used to implement GRadioButton once it's a bit more mature.
2019-06-12 05:57:26 +02:00
faissaloo
6e0e9481a4
GWindow: Make SerenityKeys labels look better
2019-06-09 17:01:25 +01:00
faissaloo
185bff6714
GWindow: SerenityKeys refactor
2019-06-08 15:13:16 +01:00
Andreas Kling
39d1a9ae66
Meta: Tweak .clang-format to not wrap braces after enums.
2019-06-07 17:13:23 +02:00
Andreas Kling
7ad8790d80
LibGUI: Run clang-format on everything.
2019-06-07 11:46:02 +02:00
Andreas Kling
a2a6bb93bc
GScrollBar: Use increment/decrement naming consistently.
2019-06-07 10:56:30 +02:00
Andreas Kling
164742f316
GScrollBar: Keep scrolling while pushing down increment/decrement button.
2019-06-07 10:43:10 +02:00
Andreas Kling
0ece5fee14
GTextEditor: Set the vertical scrollbar step size to the line height.
...
This makes us scroll one line at a time.
2019-06-07 10:42:59 +02:00
faissaloo
d449cda3d8
GWindow: Highlight for multicharacter SerenityKeys
2019-06-03 21:04:50 +01:00
Robin Burchell
ab004f73bf
Painter: Reduce the number of draw_text overloads to only involve StringView
...
No more char + int sequences, as that's literally what StringView is for.
2019-06-03 20:27:05 +02:00
Robin Burchell
1024dfa81a
StringViewize a bunch of things -- mostly LibGUI
2019-06-03 20:27:05 +02:00
faissaloo
053f41f4f9
GWindow: Leave SerenityKey mode if non-existent keybind is used
2019-06-03 18:13:41 +01:00
faissaloo
72264661fd
GWindow: Add SerenityKeys minimum functionality
2019-06-03 16:03:19 +01:00
Andreas Kling
51581c21fc
WindowServer+LibGUI: Add a way to bring a window to the front.
...
GWindow::move_to_front() can now be used to move a window to the top of
the window stack.
We use this in Terminal to bring the settings window to the front if it
already exists when it's requested, in case it's hiding behind something.
2019-06-01 20:10:37 +02:00
Andreas Kling
fdf3608c8a
Update Badge<T> instantiations to simply be {}.
2019-05-31 15:44:04 +02:00
Robin Burchell
0dc9af5f7e
Add clang-format file
...
Also run it across the whole tree to get everything using the One True Style.
We don't yet run this in an automated fashion as it's a little slow, but
there is a snippet to do so in makeall.sh.
2019-05-28 17:31:20 +02:00
Andreas Kling
ca4d65ba59
LibGUI: Add a GListView widget.
...
GListView displays a single column of data from a GModel.
2019-05-27 21:44:39 +02:00
Christopher Dumas
e3f81bce49
IRC client setttings, Terminal settings, more WM settings
2019-05-27 21:40:53 +02:00
Robin Burchell
9d2b08e06e
LibCore: Add CDirIterator, and use it in everything rather than readdir
2019-05-27 15:27:23 +02:00
Andreas Kling
3873c51781
LibCore: Add CObject::for_each_child_of_type<T>()
...
Use this to iterate over all the GRadioButtons in a group.
2019-05-27 04:18:24 +02:00
Andreas Kling
0c85d3dba9
LibCore+LibGUI: Add is<T>(CObject&) and to<T>(CObject&) helpers.
2019-05-27 04:06:01 +02:00
Andreas Kling
723ba91f74
LibGUI: Add GWidget::for_each_child_widget(callback).
2019-05-27 03:52:33 +02:00