1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 12:38:12 +00:00
Commit graph

27 commits

Author SHA1 Message Date
Andreas Kling
dc28c07fa5 Applications: Move to Userland/Applications/ 2021-01-12 12:05:23 +01:00
AnotherTest
4bc33ee3ae Spreadsheet: Drop all references to example windows when closing them
Fixes #4716.
2021-01-02 17:15:46 +01:00
AnotherTest
e080a4f74a Spreadsheet: Avoid OOB access and use-after-move in selection 2021-01-02 17:15:46 +01:00
Stephan Unverwerth
b4d1390714 LibGFX: Move default_xxx_font() methods from Font to FontDatabase
When we have an abstract font class it makes no sense to keep
these methods in the Font class.
2020-12-30 20:40:30 +01:00
Andreas Kling
7dc5a3ead8 LibGUI: Rewrite layout system in terms of min and max sizes
This patch removes size policies and preferred sizes, and replaces them
with min-size and max-size for each widget.

Box layout now works in 3 passes:

    1) Set all items (widgets/spacers) to their min-size
    2) Distribute remaining space evenly, respecting max-size
    3) Place widgets one after the other, adding spacing in between

I've also added convenience helpers for setting a fixed size (which is
the same as setting min-size and max-size to the same value.)

This significantly reduces the verbosity of widget layout and makes GML
a bit more pleasant to write, too. :^)
2020-12-30 01:36:41 +01:00
AnotherTest
f606e78556 Spreadsheet: Show a small inline doc window for the "current" function
If the user is typing in the cell editor and has the cursor in a
function call, try to show a tip for the arguments of that function:
(cursor denoted by `|`)
```
sum(|
```
should show:
```
sum(cell names)
```
in a tooltip-like window below the editor.
2020-12-29 00:58:43 +01:00
AnotherTest
aa5b43a2bc Spreadsheet: Highlight the source causing an exception in red
This commit makes the cell editor highlight the likely source of the
exception in red.
2020-12-29 00:58:43 +01:00
Xavier Cooney
5f58fe1643 Spreadsheet: Prompt user before closing with unsaved changes 2020-12-23 15:41:49 +01:00
AnotherTest
b3a9a25416 Spreadsheet: Make it possible to rename sheets 2020-12-22 23:35:29 +01:00
Linus Groh
af80d71abc Spreadsheet: Reduce top bar default height
50px is a bit extreme, it's down to 26px high now. Still a bit larger
than a regular GUI::TextBox but enough to look decent, even with the
help button in there.

Closes #3905.
2020-12-12 20:09:55 +01:00
AnotherTest
b532b2d3ca Spreadsheet: Clear callbacks on persistent widgets before tearing tabs down
Otherwise changes to the widgets would cause all sorts of updates on
half-deleted cells.
Fixes #4171.
2020-11-30 12:07:45 +01:00
AnotherTest
7878596532 Spreadsheet: Update the view when using the cell editor 2020-11-08 21:46:13 +01:00
AnotherTest
1bd3a2d09f Spreadsheet: Add support for example views and hyperlinks in the docs
Now the functions can actually be demonstrated by small examples,
embedded right inside the documentation via:
spreadsheet://example/<page>#<example_name>

Also allows pages to link to each other via the same scheme:
spreadsheet://doc/<page>
2020-10-31 15:40:13 +01:00
asynts
f005548d56 Spreadsheet: Use new format functions.
In a few places I also simplified a few format strings:

    -outln("{} item{}", items, items.size() == 1 ? ' ' : 's');
    +outln("{} item(s)", items);

In my opinion this is more readable and in some places it incorrectly
wrote '0 item' which is "fixed" now. In other places the placeholder
space looked weird.
2020-10-06 15:28:39 +02:00
AnotherTest
e0b7833078 Spreadsheet: Do not clear cells when ctrl-selecting 2020-08-28 09:22:17 +02:00
AnotherTest
a5a3e5a178 Spreadsheet: Add support for changing multiple cells at once
Just select many cells and use the cell editor! so easy!
2020-08-27 10:27:20 +02:00
AnotherTest
cb7fe4fe7c Spreadsheet: Add support for multiple sheets
This also refactors the js integration stuff to allow sheets to
reference each other safely.
2020-08-27 10:27:20 +02:00
AnotherTest
e1f5f709ee Spreadsheet: Move sheet management to a Workbook class 2020-08-27 10:27:20 +02:00
Andreas Kling
d125c624c6 Spreadsheet: Use a fixed-width font in the cell editor 2020-08-26 17:00:40 +02:00
Andreas Kling
44e371635e LibGUI: Move table view headers into their own widget
This patch introduces the HeaderView class, which is a widget that
implements the column headers of TableView and TreeView.

This greatly simplifies event management in the view implementations
and also makes it much easier to eventually implement row headers.
2020-08-26 00:51:35 +02:00
Andreas Kling
965ccf5242 Spreadsheet: Focus the spreadsheet table on startup 2020-08-26 00:51:35 +02:00
AnotherTest
3320bb45d1 Spreadsheet: Add "Save As" 2020-08-25 09:46:28 +02:00
AnotherTest
fdf0660064 Spreadsheet: Implement state-preserving saves and loads 2020-08-25 09:46:28 +02:00
AnotherTest
de13c6939d Spreadsheet: Add a syntax highlighter to the cell editor 2020-08-24 19:15:07 +02:00
AnotherTest
3a07f6e345 Spreadsheet: Document runtime functions and add a help window
...that can automatically generate documentation pages from the objects.
2020-08-24 18:21:33 +02:00
AnotherTest
12cf3e13c0 Spreadsheet: Add a topbar with a text editor 2020-08-24 18:21:33 +02:00
AnotherTest
a6ebd29aa5 Spreadsheet: Start making a spreadsheet application 2020-08-24 18:21:33 +02:00