Commit Graph

693 Commits

Author SHA1 Message Date
Martín Lucas Golini
c530e4bd6e feat: add cross-platform file association management
Add an EE::System::FileAssociation abstraction with XDG, Windows,
and macOS implementations.

Expose extensions from syntax predefinitions and add custom widget
support to UISettingsPanel. Add an ecode settings page for selecting
file associations and installing an XDG desktop entry.

Apply changes asynchronously with lifecycle-safe UI handling, disable
controls while applying, and avoid redundant XDG database updates.

Add translations and coverage for the new functionality.

Implements SpartanJ/ecode#192
2026-09-17 11:04:25 -03:00
Martín Lucas Golini
4e3c2d966f ecode: allow deleting untracked files from Git status
- Add a Delete action for untracked files and the Untracked section, with
  confirmation before permanently removing the selected paths.

  - Decode Git-quoted status paths using new byte-oriented std::string
  String::escape() and String::unescape() overloads, preventing quoted or
  octal-escaped filenames from breaking deletion.

  - Add translations and regression tests for string escaping and quoted
  untracked paths.
2026-09-15 13:19:24 -03:00
Martín Lucas Golini
071bc5d697 Add optional smooth scrolling across UI scrollable widgets
Introduce UIScrollController to provide frame-rate-independent wheel
interpolation, touch dragging, and momentum for code editors, terminals,
scroll views, and scrollable widgets while preserving the legacy instant
scrolling path.

Add a UISceneNode-level smooth-scrolling policy. Embedded scenes inherit
the root scene setting, new widgets snapshot it during construction, and
setSmoothScrollEnabled() can optionally apply changes to existing widgets
across the complete embedded-scene hierarchy.

Move native macOS scrolling and title-bar helpers into PlatformHelper,
enable native momentum from UIApplication, and explicitly enable it in
ecode. Preserve precise SDL2 and SDL3 wheel deltas for fractional momentum
events without changing normal integer wheel steps.

Replace the separate editor and terminal preferences in ecode and eterm
with one global smooth-scrolling setting, including legacy configuration
migration, live updates, and localized settings text.

Improve UITouchDraggableWidget momentum handling and add regression tests
for scrolling interpolation, pixel-aligned editor positions, scene
inheritance, widget overrides, and immediate policy application.
2026-09-13 20:27:37 -03:00
Martín Lucas Golini
42de99cf3b Fix GL resource sharing across native application windows
Decouple GL object sharing between native windows from auxiliary worker-thread context support. Platforms without threaded GL contexts, such as Haiku, must still share textures and other GL resources between their window contexts.

Always configure SDL_GL_SHARE_WITH_CURRENT_CONTEXT according to the requested context settings, while continuing to create the auxiliary thread context only on supported platforms. Explicitly reset the SDL attribute for non-shared contexts to avoid leaking state into subsequent window creation.

Apply the fix to both SDL2 and SDL3 backends. Also link the Haiku unit test executable against libbsd and libnetwork to resolve its PTY and socket dependencies.
2026-09-12 01:51:17 -03:00
Martín Lucas Golini
3effffd16f Add shared controls for multi-file diff views
- Introduce UIMultiDiffView as a first-class container for multi-file diffs, with a compact toolbar for expanding or collapsing all files, switching between unified and split views, and displaying aggregate file and line-change statistics.
	- Calculate addition and removal totals during diff preparation so asynchronously prepared diffs do not need to rescan their contents on the UI thread. Cache the child diff views and expose the multi-diff state through the new component.
	- Use UIMultiDiffView for regular diff tabs and Git commit details, removing the duplicated commit-specific toolbar, styling logic, tokenizer state, and view-mode handling. Preserve the original Git commit toolbar appearance, spacing, icons, tooltips, and colored changed-files summary.
	- Keep the existing UIDiffView multi-file factory available for compatibility and add regression coverage for aggregate statistics, toolbar visibility, unified/split propagation, collapse state, prepared diffs, and large patches.
	- Add localized changed-files summaries to all ecode translation catalogs.
	- Fix the secondary-window UI test to use the appropriate std::string assertion helper.
2026-09-10 23:15:46 -03:00
Martín Lucas Golini
71ede34599 eepp: add reusable UISettingsPanel
- add the generic settings model and panel to EE::UI::Tools
  - support category navigation, filtering, and lazy materialization
  - add UISettingsPanel model and filtering tests

ecode: migrate settings to UISettingsPanel
  - replace the application-specific settings model
  - use the generic settings panel implementation
  - add monitor refresh rate as a frame limit option
  - normalize UI labels and translations

eterm: add persistent configuration and settings panel
  - persist application preferences and window state
  - use saved values as defaults for command-line options
  - persist command-line overrides
  - add graphical settings with live application
  - expose renderer, terminal behavior, appearance, font, and scale options
2026-09-09 00:56:03 -03:00
Martín Lucas Golini
64512ab44d eterm: expand tab controls and fix maximized tab lifecycle
- add ellipsized tabs and ecode-style context actions to eterm
  - support session rename, exclusive mode, tab movement, and maximize/restore
  - restore maximized tab widgets before close or split operations
  - track detached tab state directly to prevent stale references in ecode
  - keep dirty rows valid during asynchronous terminal resize
  - expose eterm's widget inspector and disable default UI effects
  - localize the new exclusive-mode action
2026-09-08 01:57:35 -03:00
Martín Lucas Golini
8e5d180a4d Optimize editor initialization and multi-file diff loading
- Share immutable built-in document commands, editor command tables, default keybindings, and syntax color scheme storage across editor instances. Preserve mutations through copy-on-write storage and explicit command-removal tracking.
  - Use ShortcutMap consistently with unordered lookup while retaining deterministic ordering where serialization or conflict resolution depends on it. Cache ambiguous syntax-extension checks and invalidate the cache when language definitions change.
  - Prepare Git commit-detail diffs and sub-line changes on worker threads with cancellation and stale-request protection. Release raw patch memory before UI construction and add regression coverage for prepared and cancelled diffs.
  - Add Diff Changed support and enable collapsible file headers for Diff HEAD, Diff Staged, and Diff Changes.
  - Update translations, compatibility call sites, tests, and the efsw dependency.
2026-08-30 17:35:50 -03:00
Martín Lucas Golini
3afcb3f2d2 Optimize bulk editor setup, deferred UI resources and Git plugin fixes
- Lazily compute document line hashes, avoid redundant multiline insertion
walks, and defer longest-line measurement for large or exceptionally long
text changes.

- Cache default code editor keybindings, reserve common command storage, and
create UIDiffView image viewers only when an image diff requires them.

- Keep cached screen positions coherent when descendants are queried before
dirty ancestors, and add regression coverage for ancestor movement.

- Relocate font-rendering golden images into the unit-test asset directory
and resolve image fixtures independently of the current working directory.

- Fix spurious status entries for files moved between directories. Preserve the suffix after Git's abbreviated brace notation when parsing renamed paths from numstat output. This prevents directory moves such as `bin/{ => unit_tests}/assets/...` from producing truncated synthetic untracked entries like `unit_tests`. Add regression coverage for staged files moved into a different directory.

- Git Plugin now remembers between sessions the uncommited commit message.
2026-08-30 01:05:24 -03:00
Martín Lucas Golini
7dd21fa77c Improve tag creation and add UITextEdit hint support
Add native hint text support to UITextEdit, matching UITextInput behavior and exposing configurable hint text, color, font, size, style, shadow, outline, and HintDisplay modes. Render hints only for empty
documents and preserve the correct drawing order beneath the caret.

Expose the corresponding hint CSS properties through UITextEdit and apply the theme hint color to TextEdit and TextArea widgets.

Add an “Add Tag & Push” action alongside local-only tag creation. Push only the newly created tag using an explicit refspec and the current branch’s tracked remote, falling back to origin.
2026-08-29 20:28:27 -03:00
Martín Lucas Golini
0fa99ab9d2 Expand Git History actions and branch management
- Add SmartGit-inspired context actions to Git History commits, including checkout, merge, fast-forward merge, cherry-pick, revert, branch creation, tag creation, and copying commit IDs or complete messages.
  - Order commit actions into consistent operation, ref-creation, and clipboard groups. Hide the redundant Show in Git History action inside detached history tabs while retaining it in the source-control sidebar.
  - Add a Working Tree / Index context menu with status-aware Commit and Stage actions. Track staged and unstaged availability in the history model and keep it synchronized as repository status changes.
  - Extend the Git command wrapper with operations for creating branches at commits, creating and deleting tags, deleting remote branches, cherry-picking commits, and reverting commits.
  - Support deleting tags and remote branches from the Branches view. When deleting a local branch with an upstream, optionally delete its tracked remote branch as part of the operation.
  - Add confirmation and input dialogs for branch, tag, remote-deletion, and revert workflows. Disable history-changing commit actions while another Git operation is active.
2026-08-29 15:11:08 -03:00
Martín Lucas Golini
b3d72b5acf Fixed the autocomplete crash, root cause: getDocumentSymbols() accessed mDocs from a worker thread while document lifecycle callbacks could concurrently modify the same unordered_set, corrupting its internal state.
Added a synthetic “Working Tree / Index” first row whenever the selected repository has local or staged changes.
Displays separate changed and staged counts.
Updates dynamically from normal status refreshes without reloading commit history.
Selecting it opens the shared details view in “Uncommitted changes” mode.
Shows tracked changes from HEAD through the working tree, plus untracked-file patches.
Supports both sidebar and detached History views.
The History shortcut focuses working changes when present, otherwise the newest commit.
Added the History button beside Refresh.
Added consistent 2dp spacing between the ref dropdown and both buttons.
Added translations for the new labels.
2026-08-29 03:12:27 -03:00
Martín Lucas Golini
61d9d3c7bc Improve Git History navigation and commit details
Add a detached Git Commit History tab with a traditional table layout, persistent column widths, commit focusing, and a splitter-based commit details pane.
Register the git-show-history command and expose “Show in Git History” from commit details and history context menus. Add History and Git Commit tab icons, localized titles, appropriate tooltips, and ref-aware
tab naming.
Share the commit-details layout and behavior between standalone commit tabs and detached History views. Move view creation, widget binding, state management, controls, and asynchronous changed-file loading into
CommitDetailsState.
Display complete commit metadata and messages, GitHub links, copyable commit SHAs, colored changed-file statistics, and multi-file diffs with global expand/collapse and unified/split controls.
Improve detached-history lifecycle behavior, selection and focus handling, stale-request protection, tooltip formatting, and column recalculation. Restore “Load older commits” by preserving pagination-node
semantics while asynchronous loading is in progress.
Fix expandable History rows so merge subjects and metadata render correctly without regressing generic UITreeView cells. Add recursive commit lookup for focusing nested history entries.
Add deferred tooltip-created notifications and configure History tooltips only after their widgets exist.
Preserve tokenizer-applied UITextView color ranges during layout recalculation when custom styling is enabled, preventing changed-file statistics from losing their colors after splitter resizing.
Add the required Codicons and translations, expose UIWidget pseudo-class queries, reuse cached tree-expander drawable sources, and use SmallVector for nested stylesheet property resolution.
2026-08-29 02:15:26 -03:00
Martín Lucas Golini
ef962fc61f Improve Git History navigation and asynchronous UI safety
Add a History ref selector for HEAD, local branches, remote branches, and tags without requiring checkout. Reuse cached branch-model display strings to keep large ref lists efficient.
Make deferred main-thread callbacks lifetime-safe across ecode controllers and plugins. Initialize plugin dispatchers during UIReady and extend MainThreadLifetime to support delayed and tagged dispatch.
Fix expandable Git History rows, empty merge projections, and commit-description expansion. Display only the physical first line while collapsed and avoid duplicating it in the expanded body.
Add coverage for history ref handling and preserve stale-request guards during repository and revision changes.
Fix UIImageViewer dimension reporting for sprites by displaying the underlying texture dimensions.
The Git History interface remains a work in progress.
2026-08-28 18:52:04 -03:00
Martín Lucas Golini
baaa0a62c0 Add a work-in-progress Git History view to the source-control panel.
Display bounded first-parent commit history with asynchronous loading, independent pagination, and lazily expandable merge commits. Propagate inherited exclusions through nested merges to avoid repeating already represented history.
Add custom compact history rows, loading/error/retry states, keyboard navigation, repository and history-generation guards, and lifecycle invalidation after history-changing operations.
Add a commit details tab with full commit metadata and message, changed-line totals, GitHub links when available, and a multi-file diff viewer with global collapse and unified/split controls.
Extend UIDiffView with multi-file view controls and register the required Codicons.
The Git History interface and visual design remain a work in progress.
Fix caret positioning inside shaped ligature clusters.
Add explicit closest-glyph and interpolated ligature caret-positioning modes while keeping interpolation as the default for general text geometry.
Use the original closest-glyph behavior for caret and IME positioning in UICodeEditor, UITextEdit, UITextInput, and UIConsole, preventing cursor positions from being synthesized inside ligature glyphs.
Add regression coverage for both positioning modes.
Optimize SyntaxTokenizer by returning tokenizer results in a SmallVector, avoiding heap allocations in common cases.
2026-08-28 14:43:05 -03:00
Martín Lucas Golini
66d22ea5bb Add integrated Git conflict resolution workflow
Introduce a three-pane UIMergeView with an editable shared result
document, conflict navigation and acceptance actions, live diff
highlighting, synchronized scrolling, and contextual pane labels.

Read conflict stages directly from Git's index, detect paused merge
operations, restore conflict sessions, and support resolving, staging,
recreating, continuing, committing, and aborting operations.

Add repository-aware conflict state handling, safe asynchronous
lifetimes, merge operation UI, configurable key modifiers, i18n
strings, and focused merge-view and Git conflict tests.
2026-08-27 22:18:58 -03:00
Martín Lucas Golini
7f6568cfb0 Allow to configure the default diff view (Unified vs Side by side) 2026-08-26 17:43:57 -03:00
Martín Lucas Golini
a182878837 ecode: add structured settings pages for plugins
- introduce reusable settings models, documents, and plugin settings pages
  - expose all registered plugin configuration options in the Settings panel
  - support groups, choices, editable values, lists, secrets, and JSON objects
  - stage plugin changes and persist them when the Settings window closes
  - preserve raw JSON access for advanced configuration
  - safely migrate legacy AI provider API keys
  - add translated plugin setting labels and descriptions
  - remove the obsolete plugin GUI configuration API
  - fix autocomplete signature documentation persistence
  - fix AI model catalog refresh interval loading
2026-08-26 01:37:28 -03:00
Martín Lucas Golini
932c00ae4f ecode: add centralized settings panel and simplify settings menus
- add searchable user and project settings panels
  - organize settings into navigable categories and subsections
  - apply supported configuration changes in real time
  - add direct document and terminal settings accessors
  - retain only contextual actions in the legacy settings menus
  - replace legacy configuration dialogs with inline controls
  - improve modal behavior, keyboard navigation, and persistence
  - add validation for editable settings
  - update and remove obsolete i18n strings
2026-08-24 15:16:17 -03:00
Martín Lucas Golini
30cf6d9e97 ecode: add centralized settings panel
- add user and project settings windows with searchable tree navigation
  - centralize setting definitions with reusable bool, choice, text, numeric, and action controls
  - apply supported configuration changes reactively
  - add inline validation and editable choices for complex value types
  - disable project document options while inheriting global settings
  - migrate font, theme, language, renderer, screenshot, and terminal settings
  - improve keyboard navigation and modal shortcut isolation
  - make configuration dialogs modal
  - persist settings when the panel closes
  - add responsive dark and light theme styling
  - update translations for new settings labels and descriptions
  - add regression coverage for modal keybinding propagation
2026-08-24 13:07:43 -03:00
Martín Lucas Golini
288aa931fe ecode: add centralized settings panel
Introduce modal user and project settings panels with searchable tree navigation and live configuration updates.

  - centralize settings registration and presentation
  - add user and project settings commands and shortcuts
  - preserve operational actions in the existing settings menu
  - support boolean, choice, numeric, and action-based settings
  - restore renderer notifications and choice descriptions
  - persist settings when closing the panel
  - add translated settings strings for all supported locales
  - fix live color preview updates
2026-08-24 02:34:14 -03:00
Martín Lucas Golini
8eed5fcd58 Add configurable Tab Out support
Add an optional Tab Out behavior that moves a single cursor past configured trailing characters when pressing Tab. Expose the feature in Global Document Settings, keep it disabled by default, persist its configuration, and preserve existing selection and multi-cursor indentation behavior (SpartanJ/ecode#951).
2026-08-21 11:35:35 -03:00
Martín Lucas Golini
b02fc1f3a6 Add dynamic AI model catalog and reasoning controls
Fetch and cache the models.dev catalog asynchronously, replacing bundled model lists when catalog data is available while preserving local and user-configured providers.

Update live AI Assistant instances after refresh, defer startup requests until the UI is ready, and cancel in-flight catalog requests during shutdown. Prioritize providers with configured credentials and infer each provider's cheapest title-generation model from catalog pricing.

Add model reasoning metadata, effort controls, request serialization, chat persistence, and localized UI labels. Refresh the bundled fallback models and support API keys for arbitrary catalog providers.

Fix ACP Agent mode message chunks enqueue ordering issue (ACP thought chunks were enqueued twice while answer chunks were enqueued once).

Fix UIDropDownList WrapContent sizing so dropdown width follows its text, skin, and padding, and tighten UIDropDown automatic height sizing.
2026-08-19 01:30:56 -03:00
Martín Lucas Golini
ffabb19d60 Add configurable OpenType font features to text rendering:
Support explicit liga, calt, clig, and dlig shaping features and include
  text hints in layout caching, measurement, drawing, and character
  position calculations.

  Propagate scene-wide font feature defaults through UI text producers,
  with granular widget overrides and recursive cache invalidation. Update
  UICodeEditor and UIConsole to use shaped positioning when font features
  are enabled, including with monospaced fonts.

  Add separate UI and editor font feature settings to ecode, persist them
  as comma-separated OpenType tags, and apply changes immediately. Add
  localized menu labels, reusable Text feature conversion helpers, and
  regression coverage for shaping, positioning, propagation, and parsing.
2026-08-15 02:21:11 -03:00
Martín Lucas Golini
cb035b82ab Merge remote-tracking branch 'origin/develop' into develop 2026-08-14 13:53:07 -03:00
Martín Lucas Golini
1b901eaa02 Fix external font handling in UIFontPickerDialog
Preserve explicitly selected font styles and correctly reconcile external fonts with the asynchronously loaded system font list.

Group same-family external fonts under the Style column when styles are visible, and expose them as distinct family entries when styles are hidden. Include filenames in localized external-font labels to distinguish alternate
font versions.

Ensure system-listed regular faces remain available after asynchronous loading and add regression coverage for collisions, selection, and hidden style behavior.
2026-08-14 13:52:55 -03:00
Martín Lucas Golini
cc87ed6924 Add CSS paint ordering and stacking contexts to HTML widgets
Implement spec-oriented paint phases for normal flow, floats, and
positioned descendants, including atomic stacking groups and applicable
z-index handling for flex and grid items.

Share cached ordering between drawing and hit testing, propagate
invalidation across stacking scopes, and preserve ancestor transforms
and clipping for promoted descendants.

Add regression coverage for paint order, hit testing, reparenting,
clipping, flex ordering, and the old Reddit layout. Document the
supported stacking model and remove the completed implementation plan.
2026-08-14 01:43:34 -03:00
Martín Lucas Golini
bf750761ae ecode: add customizable debugger panel layouts
- add a reusable right-side panel managed at the application level
  - migrate debugger tabs to UITabWidgetSplitter instances
  - support moving and splitting debugger tabs across bottom and right panels
  - restrict debugger tab drops to debugger-owned panel targets
  - serialize debugger tab layouts, panel state, and table column widths
  - add pixel and percentage column-width modes to UIAbstractTableView
  - support XML/CSS configuration and an optional width-mode context menu
  - preserve percentage totals across resizing, fit-to-content, minimum widths,
    scrollbar changes, and pixel-density rounding
  - add splitter edge hiding while preserving splitter-always-show precedence
  - use EventConnection ownership for safe widget and controller lifetimes
  - validate serialized splitter layouts with structural limits
  - display project-relative source paths in debugger stack frames
  - add ecode localization strings, CSS documentation, tests, and agent rules
2026-08-14 00:17:29 -03:00
Martín Lucas Golini
6ba7de31d5 Added "Open Folder" button to the take screenshot notification. 2026-08-11 17:51:31 -03:00
Martín Lucas Golini
4789bfb5f9 ecode: add configurable screenshot support
Add an unlocked take-screenshot command and expose it under Settings -> Window with a default Print Screen binding.

Allow configuring the screenshot destination, filename pattern, and output format. Save screenshots under the ecode configuration directory by default, notify users after capture, and provide an action to open the result in the integrated image viewer.

Addresses a request in SpartanJ/ecode#950.
2026-08-11 15:43:22 -03:00
Martín Lucas Golini
6df0c0738f Add font size selection to ecode font picker:
Allow UIFontPickerDialog sections to be hidden and make ecode's UI, editor, and terminal font dialogs select both the font and its size.
Keep external fonts selectable across asynchronous font enumeration, including when they share a family name with a system font, and label them as external. Also normalize UILinearLayout weights across visible children so hidden picker columns release their space correctly.
Update font picker previews, size units, menu labels, translations, and lifetime handling.

Addresses SpartanJ/ecode#944.
2026-08-11 12:38:34 -03:00
Martín Lucas Golini
74b0454721 Refactor CSS properties to use dense IDs and bitsets:
Introduce contiguous PropertyId and ShorthandId enums backed by name-to-ID maps, replacing hash-valued property identifiers throughout the style system.
Replace PropertyIdSet's unordered set with a fixed-size bitset, eliminating heap allocations during style state changes while providing deterministic ascending iteration.
Keep name hashes for stylesheet storage and unknown or custom properties, while using dense typed IDs for registered-property lookup and dispatch.
Preserve property aliases and the public Checked compatibility identifier.
Add transaction-end reconciliation for interdependent image sizing properties, deferring percentage-based calculations until their containing block is resolved.
Keep formatting-context-owned sizes intact for table cells and inline content.
Add validation and tests for dense built-in registration, custom IDs, aliases, bitset operations, allocation-free storage, unknown properties, property application order, and image sizing regressions.
2026-08-05 20:53:13 -03:00
Martín Lucas Golini
861b2bc3c4 Fix driver-dependent patterned border rasterization
Snap dotted and dashed border geometry to physical pixels so centered
  patterns cannot begin on ambiguous half-pixel coordinates. This makes
  rectangular dot placement deterministic across llvmpipe and macOS GPU
  drivers.

  Update the old Reddit golden image to use the snapped dot phase.

Optimize compile-time header dependencies

  - Extract lightweight singleton declarations.
  - Remove unnecessary core.hpp, stream, pack, and container includes.
  - Add explicit direct dependencies across system, network, graphics, and syntax headers.
  - Forward-declare stream and pack types where possible.
  - Normalize selected network headers to LF.
2026-08-02 19:20:07 -03:00
Martín Lucas Golini
48b7e7c21f ui: improve HTML inline layout and old Reddit rendering
- implement per-side CSS border styles and patterned rendering
  - preserve rectangular rasterization for thin dotted borders
  - separate CSS and native-widget border defaults
  - correct inline atomic-box and vertical-align baseline layout
  - collapse adjacent block margins in rich-text flow
  - preserve forced line breaks and formatting margins
  - size HTML text inputs from font ascent and descent
  - expose replaced-control text baselines to inline layout
  - enforce single-owner painting for inline backgrounds and borders
  - enable and update the old Reddit visual regression golden
  - add generic layout, border, and form-control regression tests
  - document spec-first HTML work and project build conventions
2026-08-02 17:48:53 -03:00
Martín Lucas Golini
a2ee615553 • Fixed the Reddit inline sibling regression.
The float-aware rich-text layout was resetting curX for every block formatting context, including inline-blocks. That made consecutive action buttons overlap. The reset is now limited to block-level BFCs;
  inline-blocks retain normal cursor advancement.

  Added:

  - An always-on deferred CSS regression covering inline anchors, inline-block siblings, and float exclusions.
  - Strict action-row and title/domain ordering checks in the opt-in Reddit visual smoke test.
  - A small CSS fixture reproducing Reddit’s layout rules.
2026-07-30 19:33:20 -03:00
Martín Lucas Golini
d3ed96919a Fix percentage margin resolution after async HTML layout
Track percentage-based margins in UIHTMLWidget and re-resolve them when
  the containing parent acquires its final size. This prevents margins
  computed against an initial zero-width container from remaining stale
  until the viewport is resized.

  Add regressions covering percentage margin recomputation and the SS64
  footer layout after a deferred stylesheet is loaded.
2026-07-30 19:08:49 -03:00
Martín Lucas Golini
943103869a fix(ui): preserve CSS order for deferred stylesheets
Reserve stylesheet source positions when link elements are encountered
  instead of assigning them when asynchronous loading completes.

  Track the stylesheet and rule ordinals explicitly so deferred external
  styles retain their document order relative to later inline styles.
  Preserve this ordering when extracting marked stylesheet rules.

  Add an SS64 regression test covering heading and button styles after a
  deferred stylesheet finishes loading.
2026-07-30 17:52:27 -03:00
Martín Lucas Golini
9fc385307a Fix percentage-sized inline SVG layout and rendering
Resolve percentage dimensions for HTML-backed widgets after their containing
block has a definite size. Apply the resolution during rich-text, flex, and
grid layout without triggering broad layout invalidation.

Rasterize SVGs using their resolved dimensions when intrinsic width or height
attributes are missing or percentage-based.

Add regression coverage for percentage-sized SVGs and the SS64 navigation
buttons and search icon.
2026-07-30 13:38:36 -03:00
Martín Lucas Golini
935b28c91a Fix HTML input styling and internal control layout
Treat UIHTMLInput as the stable HTML/CSS host while keeping its native
control as an anonymous implementation detail.

Prevent author CSS from matching internal control widgets, avoiding
duplicated backgrounds and other styles. Keep valid input types such as
email intact for attribute selectors while falling back to compatible
native implementations.

Synchronize the internal control with the host content box after layout,
including flex sizing, and preserve intrinsic measurement for size and
font changes. Preserve input state across dynamic type changes and make
hidden transitions reversible.

Also fix border-radius calculations and add regressions for CSS ownership,
anonymous widget isolation, dynamic type changes, input sizing, and the
Causality newsletter form.
2026-07-27 11:17:23 -03:00
Martín Lucas Golini
90f41a64aa Fix HTML viewport sizing and background shorthand parsing
- parse slash-separated background position and size without requiring whitespace
  - recognize custom-property background images following an explicit size
  - resolve root body and html minimum heights against the layout viewport
  - avoid expanding semantic document boxes to the scrollable content extent
  - handle auto margins and percentage offsets correctly for absolute positioning
  - add DuckDuckGo layout and background shorthand regression tests
  - document the Xvfb limitation with multisampled OpenGL contexts
2026-07-27 00:59:39 -03:00
Martín Lucas Golini
0bf2b89970 Handle downscaled LCD glyphs with a dedicated resize path before atlas upload. This preserves row stride and RGB coverage, fixing corrupted icon-font glyphs at small sizes.
Add a golden-image regression test covering scaled subpixel glyphs from the Nonicons font.
2026-07-26 00:23:24 -03:00
Martín Lucas Golini
c0debbee9f Rollback to fix rendering. 2026-07-25 20:26:24 -03:00
Martín Lucas Golini
27a57960f4 SubPixel hinting support. 2026-07-25 18:59:20 -03:00
Martín Lucas Golini
ed46508df4 Merge branch 'feature/resource-shared-ownership' into develop 2026-07-25 01:36:21 -03:00
Martín Lucas Golini
b940407102 ecode: The custom fallback font reused the "fallback-font" resource key, replacing the built-in CJK fallback in FontService.
Fix:

  - User fallback now uses "user-fallback-font".
  - Built-in CJK and custom fallback fonts remain registered together.
  - Added and passed a regression test verifying both fallback resources remain in the chain.

Fixes in premake5.lua:

  - Removed obsolete PRECISE_F32=1; Wasm already provides precise float behavior.
  - Moved ENVIRONMENT=worker,web to final application link options.

Fixed MarkdownView not getting the correct CSS style from the base theme.
2026-07-25 01:36:00 -03:00
Martín Lucas Golini
6351332d9b Closes SpartanJ/ecode#939 2026-07-24 10:48:11 -03:00
Martín Lucas Golini
0a7984b17d Register cmake.in.
Detect as function call something like `name ()` in Vala.
2026-07-17 12:30:18 -03:00
Martín Lucas Golini
41f58374bd Pre register new extensions. 2026-07-17 12:18:41 -03:00
Martín Lucas Golini
95d0a8881a Fix CSS var resolution during style application
Resolve CSS variable values at the points where properties are applied,
inherited, propagated, and used to seed transitions. This prevents raw
var() values from leaking into widget state or transition start/end
values when style attributes, inherited properties, or state-dependent
rules are involved.

Also refresh style definitions when widgets load so selector-dependent
rules are evaluated with the final widget context, and add regression
coverage for inline style vars, inherited vars, parent-state child rules,
tab close opacity, and foreground tint transitions.
2026-07-08 20:48:27 -03:00
Martín Lucas Golini
7c931bf72e Fix again in UIScrollView scroll visibility.
Fix `whitespace: pre`.
2026-07-08 00:14:08 -03:00