Commit graph

204 commits

Author SHA1 Message Date
FrHun
dfefd1ec88 WidgetGallery: Make inspectable
WidgetGallery is only a demo anyways, and the perfect target to test the
Inspector.
2022-07-15 12:38:35 +02:00
sin-ack
3f3f45580a Everywhere: Add sv suffix to strings relying on StringView(char const*)
Each of these strings would previously rely on StringView's char const*
constructor overload, which would call __builtin_strlen on the string.
Since we now have operator ""sv, we can replace these with much simpler
versions. This opens the door to being able to remove
StringView(char const*).

No functional changes.
2022-07-12 23:11:35 +02:00
FrHun
53215be7ae WidgetGallery: Repair GML layout on BasicsTab 2022-07-04 11:15:40 +02:00
FrHun
8dd08d47f1 Applications: Remove usages of deprecated implicit conversions
These deprecated conversions are currently in place to make the system
compile, but they are to be removed soon. This prepares that.
2022-06-28 17:52:42 +01:00
FrHun
8081a8a5de LibGUI: Add layout spacer support to GML
This is a bit of a hack, but it is an easy way to finally get spacers
into GML.
This will translate well if spacers are later to become child objects of
the continer widget.
2022-06-10 21:26:06 +01:00
MacDue
8ac5f625e9 LibGfx: Rename draw_ellipse/circle to fill_ellipse/circle
This makes these functions more consistent with the non-aa painter.
2022-06-01 19:33:45 +02:00
Sam Atkins
cdffe556c8 LibGUI+Userland: Make Dialog::ExecResult an enum class 2022-05-13 16:27:43 +02:00
Sam Atkins
84b98da259 Userland: Set tab-widget properties in GML instead of code 2022-05-11 20:16:43 +02:00
MacDue
739d870091 Fire: Ignore mouse events outside the window (to the left)
This fixes a small issue where if you drag the cursor outside the
window on the left-hand side, the fire demo will still respond to
the mouse events, but wrapped around to the right of the window.
2022-05-08 18:15:12 +02:00
MacDue
934ea4faf1 Fire: Replace #defines with constexprs 2022-05-08 18:15:12 +02:00
EWouters
053fc51b7d Mandelbrot: Remove image export confirmation dialog
Andreas mentioned this dialog is not needed in the monthly update
video[^1].

[^1]: https://youtu.be/yUmHEYs5n34?t=364
2022-05-08 16:38:19 +02:00
MacDue
cf5b6c5c8d Demos/Eyes: Render eyes antialiased
This looks good, and is a good way to test ellipse rendering is
working properly.
2022-05-07 22:59:02 +02:00
Liav A
b401f278ad Userland: Re-organize /dev GPU nodes 2022-05-05 20:55:57 +02:00
EWouters
d3bc3da873 Mandelbrot: Add BMP and QOI image formats as options for export
Inspired by #13558 I added the option to export as QOI to the
Mandelbrot demo. I added BMP as well for completeness.
2022-04-20 08:19:25 -04:00
Simon Wanner
206d6ece55 LibGfx: Move other font-related files to LibGfx/Font/ 2022-04-09 23:48:18 +02:00
Idan Horowitz
086969277e Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
MacDue
593aa9aff1 Demos/LibGfxScaleDemo: Use BGRA8888 bitmap in canvas
Previously BGRx8888 was used, which produces artifacts with the new
antialiased window frames with border radii, which require alpha
blending whilst painting.
2022-03-26 18:24:11 +00:00
Lenny Maiorani
f912a48315 Userland: Change static const variables to static constexpr
`static const` variables can be computed and initialized at run-time
during initialization or the first time a function is called. Change
them to `static constexpr` to ensure they are computed at
compile-time.

This allows some removal of `strlen` because the length of the
`StringView` can be used which is pre-computed at compile-time.
2022-03-18 19:58:57 +01:00
Linus Groh
c2d11d5aa0 Eyes: Add 'Contents' action to help menu 2022-03-18 01:10:16 +01:00
Sahan Fernando
683de841e5 Kernel: Sandbox each GPU3DDevice file description into own host context 2022-03-14 17:38:18 +03:30
Sahan Fernando
fd5eaf6494 Demos: Create demo for VirGL gpu device
This is a simple demo for VirGL, that does the bare minimum required to
create and render a spinning cube (with one color per face).
2022-03-09 14:58:48 +03:30
Paulo Henrique Silva
0b3c1b4c79 Mandelbrot: Add Help menu with standard About action
Noticed that Mandelbrot didn't use the standard About action in the Help
menu. As a first patch to Serenity, this patch fixes it.
2022-03-08 18:34:14 +01:00
kleines Filmröllchen
81c042a8cd Demos/CatDog: Show different messages depending on state
There are two new sets of messages for the new application-dependent
main states of CatDog. With the current Array-based system, all message
collections must have the same number of messages, but that's not a
problem.
2022-03-02 18:10:02 +01:00
kleines Filmröllchen
145f983ee1 Demos/CatDog: Introduce inspector & artist states based on open programs
These two new main states are determined by looking at the programs the
user has open. The artist state, using the new artist catdog, is
triggered by PixelPaint and FontEditor, and the inspector state is
triggered by Inspector, Profiler and SystemMonitor. This requires CatDog
to unveil /proc/all, and, for some reason, /etc/passwd.
2022-03-02 18:10:02 +01:00
kleines Filmröllchen
93bb943394 Demos/CatDog: Refactor the main states
CatDog's state was previously handled by a bunch of booleans that all
needed to be in sync pretty accurately, but some of these are exclusive
(like alerted and sleeping). This commit introduces a simple enum for
the main states of CatDog which exclude the roaming and direction
states. The main state determines the standing image of CatDog and will
have further effects in the future.
2022-03-02 18:10:02 +01:00
kleines Filmröllchen
83d9a89275 Demos/CatDog: Let the speech bubble know about the CatDog widget
This will allow us to have better interaction between CatDog's state and
what it's saying.
2022-03-02 18:10:02 +01:00
Itamar
935d023967 Userland: Rename WindowServerConnection=>ConnectionToWindowServer
This was done with CLion's automatic rename feature.
2022-02-25 22:35:12 +01:00
thankyouverycool
653f01616c LibGUI+Apps: Adjust Splitter spacings
Different thread highlights between widgets lead to different
visual weights between splitters, even when they have the same
width or height. This means some splitters look best at odd
sizes while others even. This sets the default spacing to the
most commonly used, depending on orientation, and adjusts
spacing for a few apps based on the new paint rect.

The most consistent look across apps requires some manual
tweaking occassionally. Knurlheads, use your discretion!
2022-02-23 18:56:22 +02:00
Lenny Maiorani
0ec688f86e Demos: Use default constructors/destructors
https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#cother-other-default-operation-rules

"The compiler is more likely to get the default semantics right and
you cannot implement these functions better than the compiler."
2022-02-15 23:00:03 +02:00
Idan Horowitz
c8ab45e79f Userland: Run gml-format
This brings the existing GML files up to spec with the new requirements
2022-02-13 02:36:35 +02:00
kleines Filmröllchen
6ee597369d Meta+Userland: Run the GML formatter on CI and pre-commit
Now that the GML formatter is both perserving comments and also mostly
agrees to the existing GML style, it can be used to auto-format all the
GML files in the system. This commit does not only contain the scripts
for running the formatting on CI and the pre-commit hook, but also
initially formats all the existing GML files so that the hook is
successfull.
2022-02-07 18:39:50 +01:00
Jagger De Leo
742cca4bfe Starfield: Add app icon
Previously, Starfield used app-screensaver icon.
2022-02-01 04:11:56 +00:00
Dmitry Petrov
1662213737 Userland: Add horizontal mouse scroll support 2022-01-20 10:37:52 +01:00
mjz19910
10ec98dd38 Everywhere: Fix spelling mistakes 2022-01-07 15:44:42 +01:00
mjz19910
3102d8e160 Everywhere: Fix many spelling errors 2022-01-07 10:56:59 +01:00
Sam Atkins
f6633a1026 LibGUI+Userland: Make SortingProxyModel::create() return ErrorOr
Unfortunately, most of the users are inside constructors, (and two
others are inside callback lambdas) so the error can't propagate, but
that can be improved later.
2021-12-24 05:11:52 -08:00
Astraeus-
d12359ff20 WidgetGallery: Convert to try_create_default_icon 2021-12-18 23:36:59 +01:00
Astraeus-
1adc808664 Mouse: Convert to try_create_default_icon 2021-12-18 23:36:59 +01:00
Astraeus-
b9579de2b5 ModelGallery: Convert to try_create_default_icon 2021-12-18 23:36:59 +01:00
Astraeus-
683077c894 LibGfxScaleDemo: Convert to try_create_default_icon 2021-12-18 23:36:59 +01:00
Astraeus-
1c189dbba5 LibGfxDemo: Convert to try_create_default_icon 2021-12-18 23:36:59 +01:00
Astraeus-
4db2f5b4ae Eyes: Convert to try_create_default_icon 2021-12-18 23:36:59 +01:00
Astraeus-
b02da2442f CatDog: Convert to try_create_default_icon 2021-12-18 23:36:59 +01:00
Sam Atkins
7e05ccaa70 Demos: Cast unused smart-pointer return values to void 2021-12-05 15:31:03 +01:00
Brian Gianforcaro
cf4fa936be Everywhere: Use default execpromises argument for Core::System::pledge 2021-11-28 08:04:57 +01:00
pbrw
4d03852190 WidgetGallery: Use TRY() a lot more :^) 2021-11-25 08:49:31 +01:00
pbrw
bd61558ed8 Starfield: Use TRY() a lot more :^) 2021-11-25 08:49:31 +01:00
pbrw
9e3bc3f930 Screensaver: Use TRY() a lot more :^) 2021-11-25 08:49:31 +01:00
pbrw
14081b8a92 Mouse: Use TRY() a lot more :^) 2021-11-25 08:49:31 +01:00
pbrw
162c271eb6 ModelGallery: Use TRY() a lot more :^) 2021-11-25 08:49:31 +01:00