summaryrefslogtreecommitdiff
path: root/Userland/Applications/FontEditor
AgeCommit message (Collapse)Author
2023-05-13FontEditor: Move common restoration work into restore_state()thankyouverycool
2023-05-13FontEditor: Use resultant FSAC filename when Saving-asthankyouverycool
Fixes desync between file and title.
2023-05-13FontEditor: Use fallible {Input,Message}Boxesthankyouverycool
And replace DeprecatedString and fix misnamed argument in show_error()
2023-05-13FontEditor: Don't crash on missing iconsthankyouverycool
Instead of crashing on failed icon loading with TRY(), let's report missing but non-critical resources in detail and gracefully move on.
2023-05-13FontEditor: Rename m_edited_font => m_font and remove getterthankyouverycool
Pithier and it matches the naming convention used in FontEditor's child widgets. Since it was never used outside MainWidget and there will soon be no guarantee that m_font is nonnull, the public BitmapFont& getter has also been removed.
2023-05-13FontEditor: Remove unnecessary call to hide() NewFontDialogthankyouverycool
This workaround has not been needed since 5c92397
2023-05-13FontEditor: Remove unnecessary setters and gettersthankyouverycool
As these were only used internally, let's simplify things and prevent potential desync between widget state and saved settings by moving the logic into their respective actions.
2023-05-13FontEditor: Remove unnecessary deferred invokesthankyouverycool
Since moving initialization out of the constructor and recalculating GlyphMap's content size on range and font changes, these deferrals are no longer needed.
2023-05-13FontEditor: Make update_title() privatethankyouverycool
2023-05-13FontEditor: Tighten lambda capturesthankyouverycool
2023-05-13FontEditor: Propagate errors formatting preview textthankyouverycool
2023-05-13FontEditor: Propagate errors when loading GMLthankyouverycool
2023-05-13FontEditor: Port some instances of DeprecatedStringthankyouverycool
2023-05-13FontEditor: Iterate slope and weight lists by size()thankyouverycool
2023-05-13FontEditor: Convert Model lists to Vector<String>thankyouverycool
And propagate errors while building them.
2023-05-05LibGUI: Make `Application`'s construction fallibleLucas CHOLLET
The pattern to construct `Application` was to use the `try_create` method from the `C_OBJECT` macro. While being safe from an OOM perspective, this method doesn't propagate errors from the constructor. This patch make `Application` use the `C_OBJECT_ABSTRACT` and manually define a `create` method that can bubble up errors from the construction stage. This commit also removes the ability to use `argc` and `argv` to create an `Application`, only `Main`'s `Arguments` can be used. From a user point of view, the patch renames `try_create` => `create`, hence the huge number of modified files.
2023-05-05FontEditor: Use `LibFileSystemAccessClient`Caoimhe
2023-05-05FontEditor: Don't paint in `GlyphEditorWidget` if `m_font` is nullCaoimhe
The font isn't set in the constructor, there may be a case where the font hasn't loaded before the first paint event. Therefore, we should not paint if the font is null. All other methods should be fine.
2023-04-30LibGfx+Userland: Merge FrameShape and FrameShadow into FrameStylethankyouverycool
Previously, Frames could set both these properties along with a thickness to confusing effect: Most shapes of the same shadowing only differentiated at a thickness >= 2, and some not at all. This led to a lot of creative but ultimately superfluous choices in the code. Instead let's streamline our options, automate thickness, and get the right look without so much guesswork. Plain shadowing has been consolidated into a single Plain style, and 0 thickness can be had by setting style to NoFrame.
2023-04-30LibGUI+Userland: Port Labels to Stringthankyouverycool
2023-04-25Applications: Update man page links for applicationsTim Ledbetter
This commit updates all application man page links to point to the Applications subdirectory.
2023-04-19LibGUI+Userland: Make Menu::*add_submmenu take name using new stringKarol Kosek
2023-04-19LibGUI+Userland: Make Window::*add_menu take name using new stringKarol Kosek
2023-04-18FontEditor: Use compact InputBox for Go to Glyph actionthankyouverycool
2023-04-18LibGUI+Userland: Improve error and font handling for InputBoxthankyouverycool
Adds fallible factories, ports DeprecatedString, and rebuilds the layout to accomodate system font changes.
2023-04-15AK+Everywhere: Change URL::path() to serialize_path()MacDue
This now defaults to serializing the path with percent decoded segments (which is what all callers expect), but has an option not to. This fixes `file://` URLs with spaces in their paths. The name has been changed to serialize_path() path to make it more clear that this method will generate a new string each call (except for the cannot_be_a_base_url() case). A few callers have then been updated to avoid repeatedly calling this function.
2023-03-01LibCore+Everywhere: Remove ArgsParser::add*(char const*&)Ali Mohammad Pur
This is not guaranteed to always work correctly as ArgsParser deals in StringViews and might have a non-properly-null-terminated string as a value. As a bonus, using StringView (and DeprecatedString where necessary) leads to nicer looking code too :^)
2023-02-21Userland: Fix remaining smart pointer const-correctness issuesAndreas Kling
2023-02-10Everywhere: Remove needless copies of Error / ErrorOr instancesTimothy Flynn
Either take the underlying objects with release_* methods or move() the instances around.
2023-02-04LibGUI+Userland: Switch order of parameters for InputBox::showKarol Baraniecki
Because usage of the input_type parameter is now higher than of the placeholder parameter, this makes for a cleaner API.
2023-02-04Userland: Replace manual checking by using GUI::InputType::NonemptyTextKarol Baraniecki
Do this where we were already checking if the input was empty after the InputBox was submitted. Those places gain interactive input validation. :^)
2023-01-26LibGfx: Remove `try_` prefix from bitmap creation functionsTim Schumacher
Those don't have any non-try counterpart, so we might as well just omit it.
2023-01-13FontEditor: Fix more ignored .to_string() errorsMacDue
2023-01-07LibGUI+Userland: Rename `try_load_from_gml()` -> `load_from_gml()` :^)Sam Atkins
It's the only one, so the `try` prefix is unnecessary now.
2023-01-07Userland: Replace all uses of `load_from_gml` with `try_load_from_gml`Sam Atkins
MOAR FIXMES! ;^)
2023-01-06LibGUI+Everywhere: Use fallible Window::set_main_widget() everywhere :^)Sam Atkins
Rip that bandaid off! This does the following, in one big, awkward jump: - Replace all uses of `set_main_widget<Foo>()` with the `try` version. - Remove `set_main_widget<Foo>()`. - Rename the `try` version to just be `set_main_widget` because it's now the only one. The majority of places that call `set_main_widget<Foo>()` are inside constructors, so this unfortunately gives us a big batch of new `release_value_but_fixme_should_propagate_errors()` calls.
2023-01-02Base+Userland: Add menu item iconsBrandon Jordan
Base+Userland: Add menu item icons This adds missing icons to Presenter Presentation menu. This adds missing icon to Image Viewer View menu. This adds a scale icon for the Image Viewer and Font Editor. This moves the Fit Image to View icon to the 16x16 folder as it's now used by Image Viewer and not only Pixel Paint. This improves the fullscreen and play icons so that they fit together better.
2022-12-20FontEditor: Update preview window after pasting and deleting glyphsthankyouverycool
2022-12-20FontEditor: Add Unicode block/glyph selection Statusbar Segmentthankyouverycool
Displays the current active Unicode block range, or, if multiple glyphs are selected, their count. Clicking toggles the Unicode block ListView.
2022-12-20LibGUI+FontEditor: Restore normalized selections on Undo/Redothankyouverycool
Selections are always normalized when saving undo commands. The restore_selection() function reverses this process so negatively sized selections (created right-to-left) continue to resize correctly with the keyboard when restored.
2022-12-20FontEditor: Set Unicode ListView's focus proxy to its search boxthankyouverycool
Provides a visual cue that arrow key input is shared between these widgets.
2022-12-20FontEditor: Remove unused includesthankyouverycool
2022-12-06Everywhere: Rename to_{string => deprecated_string}() where applicableLinus Groh
This will make it easier to support both string types at the same time while we convert code, and tracking down remaining uses. One big exception is Value::to_string() in LibJS, where the name is dictated by the ToString AO.
2022-12-06AK+Everywhere: Rename String to DeprecatedStringLinus Groh
We have a new, improved string type coming up in AK (OOM aware, no null state), and while it's going to use UTF-8, the name UTF8String is a mouthful - so let's free up the String name by renaming the existing class. Making the old one have an annoying name will hopefully also help with quick adoption :^)
2022-11-19FontEditor: Include file basename in error messages when availablethankyouverycool
And write messages in the [action] failed: [error] format to match common error message formatting elsewhere in Userland.
2022-11-19LibGUI+Applications: Allow GlyphMapWidget's set_font() to failthankyouverycool
And TRY early during initialization in FontEditor to leave the app in a valid state on error. Fixes OOM crashes when cloning the original font for highlight modifications.
2022-11-19LibGUI+FontEditor: Allow system emoji to be toggled in GlyphMapWidgetthankyouverycool
And remove their red backgrounds when visible to not be confused with deletion highlights.
2022-11-19FontEditor: Add Layout options to View menuthankyouverycool
Like other apps, FontEditor now organizes widget visibility toggles under a View->Layout submenu. The main toolbar and the status bar can now be turned on and off.
2022-11-19FontEditor: Remove redundant set_scale() helperthankyouverycool
2022-11-19FontEditor: Remove overzealous find-and-replace ""sv operatorthankyouverycool