Age | Commit message (Collapse) | Author |
|
We achieve this by allowing you to specify custom traits for the key type.
For convenience, we also provide a CaseInsensitiveStringTraits for String.
|
|
Use this in GSpinBox to implement auto-increment / auto-decrement while you
are pressing down the respective buttons. :^)
|
|
|
|
Also add an AudioServer that (right now) doesn't do much.
It tries to open, parse, and play a wav file. In the future, it can do more.
My general thinking here here is that /dev/audio will be "owned" by AudioServer,
and we'll do mixing in software before passing buffers off to the kernel
to play, but we have to start somewhere.
|
|
This means that single-line draw_text() calls don't get any additional line
spacing added. Which makes things look right.
|
|
This is really just to show off multi-line GLabels :^)
|
|
This patch makes it possible to draw_text() things like "ABC\nDEF\nGHI".
It works by breaking the string into lines, then computing a bounding rect
for all the lines, and finally aligning each line appropriately within
the bounding rect and drawing them one by one.
Fixes #297.
|
|
stream of events to
This is effectively a mouse grab except that we don't require any client
coordination to request it (which is probably OK, and certainly a lot
simpler to implement).
This prevents e.g. dragging the mouse cursor out of paint and over the
terminal from selecting text unexpectedly.
|
|
|
|
Added a main widget for the text editor as a stepping stone to add new features.
|
|
Here goes the first attempt at using VisualBuilder to make an application.
There are many features missing that we are gonna have to implement,
noticeably custom widgets (for the glyph editor and glyph map widgets)
but this patch already moves most of the UI layout to a form file. :^)
|
|
|
|
We shouldn't allow constructing e.g an OwnPtr from a RefPtr, and similar
conversions. Instead just delete those functions so the compiler whines
loudly if you try to use them.
This patch also deletes constructing OwnPtr from a WeakPtr, even though
that *may* be a valid thing to do, it's sufficiently weird that we can
make the client jump through some hoops if he really wants it. :^)
|
|
Regardless of mode, made the knob container clickable so the knob position
can be moved without dragging the knob itself.
Added a 3rd GSlider to the WidgetGallery showing the proportional mode in
action.
|
|
This patch removes copy_ref() from RefPtr and NonnullRefPtr. This means that
it's now okay to simply copy these smart pointers instead:
- RefPtr = RefPtr // Okay!
- RefPtr = NonnullRefPtr // Okay!
- NonnullRefPtr = NonnullRefPtr // Okay!
- NonnullRefPtr = RefPtr // Not okay, since RefPtr can be null.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
There's very little reason to take NonnullRefPtr&& in arguments really.
You can avoid ref-count churn in the cases where ownership is transferred
from the caller to the callee, but that's a pretty unusual situation and
not worth optimizing for at this stage.
|
|
|
|
Taking a RefPtr<GraphicsBitmap>&& was just making things unnecessarily
complicated for clients, and didn't actually improve anything.
|
|
|
|
|
|
This is obviously more readable. If we ever run into a situation where
ref count churn is actually causing trouble in the future, we can deal with
it then. For now, let's keep it simple. :^)
|
|
I had a silly ambition that we would avoid unnecessary ref count churn by
forcing explicit use of "copy_ref()" wherever a copy was actually needed.
This was making RefPtr a bit clunky to work with, for no real benefit.
This patch adds the missing copy construction/assignment stuff to RefPtr.
|
|
|
|
|
|
|
|
|
|
|
|
And some trivial tests.
|
|
It seems like the newest Ubuntu supported by Travis is 16.04. The bundled
gcc is unable to compile the trendy and modern Serenity code, so let's try
to install a newer GCC on the CI bot. :^)
|
|
|
|
Since we're gonna want to use this for building other apps, it should be
the very first thing we build.
|
|
Also make sure the generated main widget has autofill turned on.
|
|
This is a simple test app with its UI generated from a VisualBuilder form.
The name is probably silly, but who cares. :^)
|
|
|
|
|
|
The basic idea is that you would use it like this:
MyWidget::MyWidget(GWidget* parent)
: GWidget(parent)
{
m_ui = new UI_MyWidget;
set_main_widget(m_ui->main_widget);
...
}
|
|
|
|
|
|
This will be useful for things like the VisualBuilder code generator.
|
|
|
|
It was silly to duplicate this functionality in so many places. Now everyone
uses CProcessStatisticsReader to parse /proc/all :^)
|
|
|
|
|
|
Also tweaked CProcessStatisticsReader a bit to simplify the API.
|