This adds a scale factor to Painter, which will be used for HighDPI
support. It's also a step towards general affine transforms on Painters.
All of Painter's public API takes logical coordinates, while some
internals deal with physical coordinates now. If scale == 1, logical
and physical coordinates are the same. For scale == 2, a 200x100 bitmap
would be covered by a logical {0, 0, 100, 50} rect, while its physical
size would be {0, 0, 200, 100}.
Most of Painter's functions just assert that scale() == 1 is for now,
but most functions called by WindowServer are updated to handle
arbitrary (integer) scale.
Also add a new Demo "LibGfxScaleDemo" that covers the converted
functions and that can be used to iteratively add scaling support
to more functions.
To make Painter's interface deal with logical coordinates only,
make translation() and clip_rect() non-public.
I have a local branch that gets us past implementation stage 1
in this doc, and it seems like a useful enough checkpoint to
upstream it and then iterate in tree.
* Add SERENITY_ARCH option to CMake for selecting the target toolchain
* Port all build scripts but continue to use i686
* Update GitHub Actions cache to include BuildIt.sh
We already have installation instructions for ubuntu but not yet for
Debian. Gcc-9 is not available on Debian stable so instructions for
switching to and from Debian testing are added.
Gcc 8.3.0 (which is the current version in debian 10 stable) seems to
fail at building AK. New people might get stuck when they try to run
make inside the ./Build folder and fail at building serenity.
It seems that new people go to the build instructions from the main
README, don't see Windows and are then stuck.
We do have instructions for Windows, but they aren't noted in the build
instructions, so new people get stuck thinking there's no way to build
on Windows.
Inspired by #3047, and my struggles to understand how cmake is supposed to work ^^
Thanks to @bgianfo, who made me realize that ninja can be used just like make.
No idea why I didn't notice that earlier.
This now descibes how to get the regular `make run` workflow to work
under Windows using native QEMU. It describes how to override the QEMU
binary path, as well as overriding the SerenityOS disk image file
location with a native Windows path.
Also fixes some minor spelling and punctuation issues.
WSL2 is now available in non-insider builds of Windows, starting
with version 2004.
Add a filesystem note regarding use of /mnt/c et al from WSL2 for
compiling serenity. Namely, recommend against it as the performance
across the 9p file system protocol is terrible for IO heavy jobs.
Toolchain/BuiltIt.sh expected a version of cmake which
apt did not provide for my system. Added note of the
expected version and where to find a newer version.
This commit updates CLionConfiguration.md and NotesOnWSL.md so that
they comply with new build system. In addition to that, the WSL doc
is updated to include instructions to run qemu (and serenity) natively
on Windows, without needing an X-window server.
List of changes:
- The cmake command has been moved away from the main build instructions since
the BuildIt script executes it automatically
- The ninja install has been clarified to take the BuildIt script into account
and explain that the folder needs to be cleaned before executing cmake
- The ports instructions have been updated to use the make commands
- "brew install bash" has been added to the macOS prerequisites as per #2132
- The build instructions headers have been indented to group the prerequisites
together
- The build instructions code snippets have been standardized into code blocks
- Fixed a typo
It didn't feel right to have a "DHCPClient" in a "Servers" directory.
Rename this to Services to better reflect the type of programs we'll
be putting in there.
This commit adds a CMakeLists.txt file that will be used by CLion to
configure the project and documentation explaining the steps to follow.
Configuring CLion this way enables important features like code
completion and file search. The configuration isn't perfect. There are
source files for which CLion cannot pick up the headers and asks to
manually include them from certain directories. But for the most part,
it works all right.
\0 pointed out that this is not mentioned anywhere, technically making
it a "local privilege escalation" bug.
This patch adds it to the documentation, and I've also paid out the
first $5 bounty to the "Kiwis for Kiwi" charity as per \0's request!
http://serenityos.org/bounty/kiwis4kiwi.png
This is only meant to be about higher-level coding style, not the small
things like brace placement, indentation, etc. For all of that we just
obey clang-format.