Commit graph

3195 commits

Author SHA1 Message Date
djwisdom
db31758768 Base+Fonts: Add Lucidity Mono Regular terminal font 2025-01-12 19:34:22 -05:00
djwisdom
a2fc8bbd36 Base+Fonts: Add Lucidity Mono Bold terminal font 2025-01-12 19:33:36 -05:00
Davi
e166003179 Base+Meta: Add Canadian Provincial flags 2025-01-02 08:15:38 -05:00
MacDue
8918e915d3 LibGfx: Support painting "inactive" windows in plastic window theme 2024-12-30 06:36:48 -05:00
MacDue
026bbb46f2 LibGfx: Fix position of maximized glass window theme title buttons
Previously, the buttons would be cropped (by the border thickness) as
the border is not shown on maximized windows. This patch adjusts the
button positions to correct for that.
2024-12-30 06:36:48 -05:00
Liav A.
439428b464 Base: Mark all mounts in /etc/fstab as immutable
These mounts are the base set of mounts we need for a fully functional
system. The bind mounts are also there for protection from malicious
software or accidental overwrite/deletion of files.

Therefore, marking these mounts as immutable makes sense, because they
should not be changed during runtime anyway.
2024-12-23 20:38:38 +01:00
Liav A.
1dfc9e2df3 Kernel+Userland: Add immutable mounts
Immutable mounts are mounts that can't be changed in any aspect, if the
VFSRootContext that hold them is used by a process. This includes two
operations on a mount:
1. Trying to remove the mount from the mount table.
2. Trying to change the flags of the mount.

The condition of a VFSRootContext being held by a process or not is
crucial, as the intention is to allow removal of mounts that marked as
immutable if the VFSRootContext is not being used anymore (for example,
if the container that was created with such context stopped).

Marking mounts as immutable on the first VFS root context essentially
ensures they will never be modified because there will be a process
using that context (which is the "main" VFS root context in the system
runtime).

It should be noted that setting a mount as immutable can be done in
creation time of the mount by passing the MS_IMMUTABLE flag, or by doing
a remount with MS_IMMUTABLE flag.
2024-12-23 20:38:38 +01:00
MacDue
cd2a614732 Base: Add some missing window icons to Redmond Plastic 2024-12-22 13:11:10 -05:00
MacDue
ed1405a02d Base: Add some missing window icons to Redmond Glass 2024-12-22 13:11:10 -05:00
MacDue
df59b54a45 LibGfx: Add "Redmond Glass" window theme
This adds a window theme that aims to imitate the default Windows 7
theme (known as Aero). This initial version mainly focuses on window
frames along with minor taskbar theming.

Currently, the colors for the window frames are hardcoded, but the
actual gradient painting uses the LibGfx gradient support, so it should
be fairly easy to make configurable.
2024-12-17 19:04:58 -05:00
MacDue
0531955673 LibGfx: Add "Redmond Plastic" window theme
This adds a window theme that aims to imitate the default Windows XP
theme (known as Luna). This initial version mainly focuses on window
frames along with minor taskbar theming.

Currently, the colors for the window frames are hardcoded, but the
actual gradient painting uses the LibGfx gradient support, so it should
be fairly easy to make configurable.
2024-12-17 19:04:58 -05:00
Ninad Sachania
dd9960680f Games/BrickGame: Update man page to indicate Key_Z rotates left 2024-11-21 19:06:15 -05:00
MacDue
437cb55159 notify: Add --launch-url option
This also makes the icon path an option (rather than a positional
argument) for convenience, as both `--icon-path` and `--launch-url` are
optional.
2024-11-17 10:18:36 -05:00
Sam Atkins
d094c2984b Inspector: Add a basic style sheet inspector
Choosing options from the `<select>` will load and display that style
sheet's source text, with some checks to make sure that the text that
just loaded is the one we currently want.

The UI is a little goofy when scrolling, as it uses `position: sticky`
which we don't implement yet. But that's just more motivation to
implement it! :^)

(cherry picked from commit da171c3230caaee53213d0dd04007c9b4343e3e2)
2024-11-15 23:10:03 -05:00
Sam Atkins
86b610e38a Inspector: Remove border-radius for tab areas
This wasn't visible, until I tried adding a top toolbar to a tab area,
which made it look silly.

(cherry picked from commit ced7b6de5e7b6fbe2b2739158d0116339901b4c3)
2024-11-15 23:10:03 -05:00
Kostya Farber
cec134792e Qt: Add box icon to line box debug menu action
(cherry picked from commit 3e7faae6472d9696637d58f30994199a28dddc01)
2024-11-12 07:14:25 -05:00
Timothy Flynn
1a202901ba LibWebView: Auto-select subtext when editing DOM nodes/attributes
This adds the following behavior for the DOM node/attribute editor in
the Inspector:

* If the user double clicks on an attribute name, the name is selected.
* If the user double clicks on an attribute value, the value text (sans
  the surrounding quotes) is selected.
* Otherwise, double clicks select the entire text range.

(cherry picked from commit 7fff00972d667e7c83ed0336dc8e7f8ddbd91298)
2024-11-12 07:13:58 -05:00
Gingeh
1459d48b26 LibWeb: Use substring matching for content filters
(cherry picked from commit 2e5edcf27e7d2a212043a7ac1b906217b357b964)
2024-11-10 10:46:01 -05:00
Chase Willden
8d21f70c75 Base: Navigate DOM tree with arrows
(cherry picked from commit 9d82e8112493575f78f66b1a0dc65ae0e791e70b)
2024-11-10 10:46:01 -05:00
Gasim Gasimzada
cb77f29de1 LibJS+WebContent: Implement console.table
- Expose table from console object
- Add new Table log level
- Create a JS object that represents table rows and columns
- Print table as HTML using WebContentConsoleClient

(cherry picked from commit 785180dd45ef6dcce4d847e564eca52ed0ad955b)
2024-11-08 22:32:11 -05:00
Timothy Flynn
d906e3c441 LibWebView: Include the document doctype in the exported Inspector HTML
(cherry picked from commit 2dbf846ff89a13ac3d141c72e8a89a3c6721d04b)
2024-11-08 07:44:45 -05:00
Timothy Flynn
335b527f19 LibWeb+LibWebView: Add a button to the Inspector to export its contents
When working on the Inspector's HTML, it's often kind of tricky to debug
when an element is styled / positioned incorrectly. We don't have a way
to inspect the Inspector itself.

This adds a button to the Inspector to export its HTML/CSS/JS contents
to the downloads directory. This allows for more easily testing changes,
especially by opening the exported HTML in another browser's dev tools.

We will ultimately likely remove this button (or make it hidden) by the
time we are production-ready. But it's quite useful for now.

(cherry picked from commit 3ec5c1941f25041c6bf073f2940f6035e084a4e2)
2024-11-08 07:44:45 -05:00
Timothy Flynn
78f2209723 LibWebView: De-duplicate some Inspector CSS rule blocks
After the refactor to use CSS variables for dark-mode colors in commit
ae25146b898ce8900d04c4911f1f0835681aac4e, we had duplicated blocks for
some CSS rules. This patch just unites them into one block.

(cherry picked from commit cde7c91c54574a97ec73a441669cd6dfd07e6f8f)
2024-11-08 07:44:45 -05:00
Tobias Christiansen
61848ff6c2 Inspector: Add "Fonts" tab
This adds another tab to the bottom tabs providing information
regarding the fonts computed for the currently selected DOM node.

(cherry picked from commit c3e69f2fc6ced035f59f3c78f54556a372d2fd14)
2024-11-08 07:44:45 -05:00
Tobias Christiansen
d7993d08dc Inspector: Clean up theming CSS with variables
The media queries for the different themes were all over the place,
they got consolidated in one place specifying all the colors. :^)

(cherry picked from commit ae25146b898ce8900d04c4911f1f0835681aac4e)
2024-11-08 07:44:45 -05:00
kleines Filmröllchen
a6435accd8 Base: Add CrashReporter(1), dbgputstr(2), dump_backtrace(2) manpages
Importantly, these document two nonstandard system
calls that Serenity provides.
2024-10-31 21:59:13 -04:00
Natalia Kenig
d932cc8f64 Base: Add 3 emojis 2024-10-09 19:55:11 -04:00
kleines Filmröllchen
19163e79a3 Everywhere: Format Markdown with prettier
These are the exact changes necessary to get the
next commit to pass pre-commit checks.
2024-10-04 10:46:42 -04:00
Ali Mohammad Pur
8e254334d5 Applications/Weather: Add the first GUI Jakt application 2024-10-02 08:10:54 +02:00
Sam Atkins
4335adf10e Base: Make it clear that the chonky quotation marks do in fact work now
(cherry picked from commit 9738070676154ccf2941c6a2fc99ebc3eaa5f486)
2024-09-28 14:14:28 -04:00
Liav A.
3e7eb30466 Utilities/du: Add an option to print the total size in the end
This is useful when using du on many files and wanting to get a total
size count in the end after iterating on all the directories and files.
2024-09-05 16:36:12 +02:00
Liav A.
c23005a3f0 Utiltities/elfdeps: Add an option to only print library paths
This is useful for argument passing to other utilities on the terminal.
2024-09-05 16:36:12 +02:00
Alec Murphy
99b01816ad Base: Add poweroff alias to shellrc
Just a little QoL improvement for muscle memory :^)
2024-08-23 22:16:50 +02:00
Sam Atkins
a7cf06b288 LibWebView: Sort vendor-prefixed properties last in the inspector
Previously, the legacy `-webkit-foo` properties would all be top of the
list, when they are generally not useful to inspect. Instead, put them
at the bottom, so that users can still see them if they want to, but
they're not in the way.

(cherry picked from commit 113b4da1df7ec65a8686af4e7b91e2f8d4114e2c)
2024-08-13 15:43:00 -04:00
Timothy Flynn
8999ebae52 LibWebView: Use an overflow-x value of 'auto' for Inspector containers
The Inspector looks a bit nicer if we don't paint the horizontal scroll
bars unless we need to.

(cherry picked from commit 5c73a31b4f3e18acb783b6a5c6c9a479d2956de8)
2024-08-13 15:42:42 -04:00
Timothy Flynn
75eea197c2 LibWebView: Improve scrolling of Inspector content containers
Currently, the feel of scrolling containers in the Inspector is a bit
awkward. We make the entire split-view container scrollable, then we
absolutely position the tab control buttons to force them to not scroll.
The result is that the scroll bar is painted over the tab controls, and
the tab content that we actually want to scroll has to scroll under the
tab controls. This never looked quite right.

It was basically:

    <div tab-container> <!-- Scrollable -->
        <div tab-controls /> <!-- Pinned to not be scrollable -->
        <div tab-content /> <!-- The part we actually want to scroll -->
    </div>

This patch moves the "scrollability" to just the tab content. We then
don't need to go out of our way to ensure only the content is actually
scrollable.

So we now have:

    <div tab-container> <!-- Not scrollable -->
        <div tab-controls /> <!-- Not pinned, uses normal layout -->
        <div tab-content /> <!-- Scrollable -->
    </div>

(cherry picked from commit d2c775b0ca202aa9be81ab21b0c71a8f8ac005e3)
2024-08-13 15:42:42 -04:00
Logkos
a1fdac2fc0 Base: Add 4 emojis 2024-07-27 13:29:43 -04:00
logkos
568bd04b61 Base: Add more emojis 2024-07-25 08:27:35 -04:00
Xexxa
d371e68995 Base: Add more emoji
🧙 - U+1F9D9 MAGE
🧙‍♂️ - U+1F9D9 U+200D U+2642 MAN MAGE
🧙‍♀️ - U+1F9D9 U+200D U+2640 WOMAN MAGE
🦟 - U+1F99F MOSQUITO
🏣 - U+1F3E3 JAPANESE POST OFFICE
🏬 - U+1F3EC DEPARTMENT STORE
🚊 - U+1F68A TRAM
🎎 - U+1F38E JAPANESE DOLLS
2024-07-24 08:08:33 -04:00
Timothy Flynn
2bec4276f1 LibWebView: Prevent displaying two scroll bars in the inspector console
We currently display scroll bars for the JS console and its parent tab
container. We want the console output to be separately scrollable from
the tab content, but since both containers are scrollable, we end up
with nested scroll bars. This also makes actually scrolling feel pretty
awkward.

Prevent this by making the tab container non-scrollable when the JS
console is shown.

(cherry picked from commit 4795b9206cfeb2edf573461e02f0c148b9972a36)
2024-07-22 18:27:51 -04:00
circl
6d9fa7cf12 LibWebView: Add keyboard navigation to the Inspector
(cherry picked from commit e59048e90ff5488956cf557836d94334871331e9)
2024-07-22 12:42:17 -04:00
Liav A.
ccf3d29afd Utilities: Introduce the watchfs utility
This utility is meant mainly for debugging purposes, to watch regular
files and directories being modified.
2024-07-21 12:15:44 +02:00
Liav A.
fdcfa23e01 Userland+Base: Introduce userspace implementation for running containers
Together with a first JSON file for bringing up a fully functional
BuggieBox container, we allow users to take advantage of the kernel
unsharing features that were introduced in earlier commits.
2024-07-21 11:44:23 +02:00
Liav A.
0e6624dc86 Kernel: Introduce the unshare syscall family
These 2 syscalls are responsible for unsharing resources in the system,
such as hostname, VFS root contexts and process lists.

Together with an appropriate userspace implementation, these syscalls
could be used for creating a sandbox environment (containers) for user
programs.
2024-07-21 11:44:23 +02:00
Liav A.
dd59fe35c7 Kernel+Userland: Reduce jails to be a simple boolean flag
The whole concept of Jails was far more complicated than I actually want
it to be, so let's reduce the complexity of how it works from now on.
Please note that we always leaked the attach count of a Jail object in
the fork syscall if it failed midway.
Instead, we should have attach to the jail just before registering the
new Process, so we don't need to worry about unsuccessful Process
creation.

The reduction of complexity in regard to jails means that instead of
relying on jails to provide PID isolation, we could simplify the whole
idea of them to be a simple SetOnce, and let the ProcessList (now called
ScopedProcessList) to be responsible for this type of isolation.

Therefore, we apply the following changes to do so:
- We make the Jail concept no longer a class of its own. Instead, we
  simplify the idea of being jailed to a simple ProtectedValues boolean
  flag. This means that we no longer check of matching jail pointers
  anywhere in the Kernel code.
  To set a process as jailed, a new prctl option was added to set a
  Kernel SetOnce boolean flag (so it cannot change ever again).
- We provide Process & Thread methods to iterate over process lists.
  A process can either iterate on the global process list, or if it's
  attached to a scoped process list, then only over that list.
  This essentially replaces the need of checking the Jail pointer of a
  process when iterating over process lists.
2024-07-21 11:44:23 +02:00
circl
5a5c6afd2d LibWeb: Pass network error message to generated error page
(cherry picked from commit b83e82c32cf82d2b9d21271322a4a9161357f081)
2024-07-14 19:57:14 -04:00
Liav A.
a5bc15355d DeviceDeviceMapper: Remove hardcoded list of pluggable once devices
Instead, simplify things by allowing the user to specify a specific
device entry in the configuration file, by specifying a minor number.

The first example of such device is the /dev/beep, as it resides on the
"generic" device node family (as it has a major number of 1).

However, because it can be skipped (if the user disables the beep device
through a kernel commandline option), we can't just create it blindly.
Therefore, when iterating on the configuration file the DeviceMapper
code detects the entry has a specific minor number of 10, and creates
a special DeviceNodeMatch (with a specific minor number being included).
When an event from /dev/devctl that notifies on the existence of the
/dev/beep device arrives, we find this specific match and don't create
an actual DeviceNodeFamily object, but rather blindly create a device
node.Mapper: Remove the concept of pluggable once devices
2024-07-12 18:44:49 -04:00
Liav A.
f8851b9cf2 DeviceMapper: Don't hardcode a list of device node families
Instead, let the user define them through a configuration file which can
be written with the assistance of /sys/kernel/chardev_major_allocs and
/sys/kernel/blockdev_major_allocs files.
2024-07-12 18:44:49 -04:00
Liav A.
aa2d76cd78 Utilities: Add the lsdev utility
This utility lists all devices' major number allocations, for character
and block devices. It can help the user to figure out the DeviceMapper
service manages spawning of device nodes in /dev and other associated
files under the /tmp/system/devicemap directory.
2024-07-06 21:42:32 +02:00
kleines Filmröllchen
e11f84f86d crash: Make everything more architecture-independent
- Document exactly which crash features are available on which
  architectures. There's several interesting crash tests we will want to
  add for specific architectures, such as misaligned memory accesses.
- Don't compile the divide by zero crash test on RISC-V, as they simply
  don't crash here.
- Rename the test for "x86 User Mode Instruction Prevention" to a more
  generic "try to execute a priviledged instruction"; whatever that
  specifically entails on any given architecture.
- Rename a bunch of internal variables to more generic names.
- Wrap the x86-specific implementation of "execute non executable
  memory" in architecture preprocessor checks.
2024-06-29 17:36:49 +02:00