Commit Graph
763 Commits
Author SHA1 Message Date
anthropic-code-agent[bot] 5ad46585b6 Fractional scaling 2026-03-22 19:58:16 +01:00
anthropic-code-agent[bot]andashaduri 7346db784a Add unit tests for fractional DPI scaling
- Create gui/tests directory structure with CMakeLists.txt
- Add test_fractional_scaling.cpp with comprehensive tests for:
  - 125%, 150%, 175%, 225%, 250% fractional scaling calculations
  - Correction ratio computation (system_scale / integer_ui_scale)
  - DPI detection logic from various DPI values
  - Edge cases: 100% and 200% integer scaling (no fractional)
- Tests verify the critical 250% case that was previously broken
- Integrate gui_tests into test_all executable

Co-authored-by: ashaduri <2302268+ashaduri@users.noreply.github.com>
Agent-Logs-Url: https://github.com/ashaduri/gsmartcontrol/sessions/eb9277d5-ef45-4aee-8d6c-383739f37613
2026-03-22 17:06:49 +00:00
anthropic-code-agent[bot]andashaduri 9f62577161 Fix fractional DPI scaling to store full percent and compute correction ratio
- Store full scale percent (e.g., 250 for 250%) in g_windows_fractional_scaling_percent
- Compute correction = system_scale / integer_ui_scale for proper >=200% scaling
- Update API docs to reflect full percent return value (not fractional remainder)

Co-authored-by: ashaduri <2302268+ashaduri@users.noreply.github.com>
Agent-Logs-Url: https://github.com/ashaduri/gsmartcontrol/sessions/d146d9d4-4974-4ee0-bd7b-12a84ce237ea
2026-03-22 17:00:17 +00:00
anthropic-code-agent[bot]andashaduri a79907bd05 Address PR review comments
- Add forward declaration for Gtk::Window in gsc_init.h to fix compilation
- Use std::lround() instead of truncation for proper rounding in scaling
- Update include comments to reference app_apply_fractional_scaling_to_default_size()

Changes:
1. Forward declare Gtk::Window namespace to avoid requiring Gtkmm headers
2. Replace truncating cast with std::lround() for accurate scaling (e.g., 850*1.25 = 1062.5 → 1063 instead of 1062)
3. Fix include comments in gsc_text_window.h and gsc_info_window.cpp

Co-authored-by: ashaduri <2302268+ashaduri@users.noreply.github.com>
2026-03-06 14:38:18 +00:00
anthropic-code-agent[bot]andashaduri b574294a51 Refactor: Extract fractional scaling logic to separate function
Extract the duplicated fractional scaling logic into a reusable function
`app_apply_fractional_scaling_to_default_size()` in gsc_init.cpp.

This eliminates code duplication across GscMainWindow, GscInfoWindow,
GscExecutorLogWindow, and GscTextWindow constructors.

The new function:
- Takes window pointer and configured sizes as parameters
- Handles all scaling logic in one place
- Makes it easier to maintain and extend

Addresses review feedback from @ashaduri.

Co-authored-by: ashaduri <2302268+ashaduri@users.noreply.github.com>
2026-03-06 14:26:09 +00:00
anthropic-code-agent[bot]andashaduri f1fd685441 Adjust default window sizes for fractional HiDPI scaling on Windows
When fractional HiDPI scaling is used on Windows (e.g., 125%, 150%, 250%),
GTK3 only applies integer scaling to the UI, but fonts are scaled to match
the actual DPI. This causes windows to appear smaller than they should be.

This fix detects the fractional scaling percentage during app initialization
and applies it to the default window sizes for all major windows:
- Main window (560x450 → scaled by fraction)
- Info window (850x600 → scaled by fraction)
- Executor log window (900x650 → scaled by fraction)
- Text window (800x600 → scaled by fraction)

The scaling is only applied when:
1. Fractional scaling is detected on Windows
2. No custom window size has been configured by the user

This ensures windows scale proportionally with fonts, providing a consistent
user experience on Windows with fractional HiDPI scaling.

Co-authored-by: ashaduri <2302268+ashaduri@users.noreply.github.com>
2026-03-04 21:58:06 +00:00
anthropic-code-agent[bot] bd30bbe3e5 Initial plan 2026-03-04 21:52:33 +00:00
Alexander Shaduri 5343ba9dae Cleanups 2026-03-04 22:48:21 +01:00
Alexander Shaduri 3d1e962107 Agentic: Tweak instructions. 2026-03-04 22:37:05 +01:00
Alexander Shaduri c14d7a7791 Windows: Manually install nsis since it's no longer available by default in CI. 2026-03-04 22:33:57 +01:00
Alexander Shaduri 4f3745f8ec Add copilot helper files. 2026-03-04 22:06:57 +01:00
Alexander Shaduri dadfd60ed3 Fix gcc shadow warning. 2025-11-25 19:29:46 +01:00
copilot-swe-agent[bot] 6c8fea7309 Add new natural sort order tests. 2025-11-25 19:29:28 +01:00
copilot-swe-agent[bot] 9d9e3b1a4d Update .gitignore to exclude CodeQL build directory 2025-11-25 13:00:03 +01:00
copilot-swe-agent[bot]andashaduri 54425a306a Implement natural sort order for drive names
Co-authored-by: ashaduri <2302268+ashaduri@users.noreply.github.com>
2025-11-25 12:59:41 +01:00
Alexander Shaduri be601f514d Upgrade CodeQL actions to version 4
Updated CodeQL actions to version 4 in the workflow configuration.
2025-11-18 19:44:28 +01:00
Alexander Shaduri a7c7c8190c Update CodeQL SARIF upload action to v4 2025-11-18 19:43:57 +01:00
Alexander Shaduri 44948de7d0 Fixed typos and updated visible copyright years. 2025-06-11 09:43:36 +02:00
Alexander Shaduri e2efde2d1a Updated nlohmann json to version 3.12.0. 2025-05-16 17:48:32 +04:00
Alexander Shaduri 6630116ba1 Properly implemented persistence of manually added devices (#87). Added --forget-devices option to clear the list if any of the devices causes trouble. 2025-04-28 18:51:42 +04:00
Alexander Shaduri 1f7c2b6a92 Manually added devices can be persistent now. 2025-04-28 11:19:44 +00:00
Alexander Shaduri 10ad6b74eb Merge remote-tracking branch 'origin/main' 2025-04-25 12:22:38 +04:00
Alexander Shaduri f62de567df MSYS no longer supports 32-bit Windows, so disable it in CI. 2025-04-25 12:12:52 +04:00
Alexander Shaduri d96dc79943 Merge pull request #86 from checktext00/patch-1
Update 36535 to 65535 hours in selftest log tooltip.
2025-04-17 11:32:32 +04:00
Alexander Shaduri e35c301605 Update gsc_info_window.cpp
Looking at the smartmontools code, it should be 65535 I believe.
2025-04-17 11:31:13 +04:00
checktext00 7af8dba9f3 update 36535 to 65536 hours 2025-04-16 11:58:09 +00:00
Alexander Shaduri caa80a30d1 Merge pull request #83 from stanislav-brabec/main
Typo fix in Czech desktop translation.
2025-03-12 20:46:01 +04:00
Stanislav Brabec db4928e78f Typo fix in Czech desktop translation. 2025-03-12 16:43:39 +01:00
Alexander Shaduri af96fa2cda Merge pull request #82 from stanislav-brabec/main
Add desktop translations
2025-03-11 11:55:47 +04:00
Stanislav Brabec c08ef9070b Add desktop translations
Add desktop translations imported from the openSUSE
desktop-file-translations project.
https://l10n.opensuse.org/projects/desktop-file-translations/
2025-03-10 22:10:45 +01:00
Alexander Shaduri 6fe5b43bc1 Document Vista. 2025-03-02 19:13:32 +04:00
Alexander Shaduri b3056aedd0 Update download links for 2.0.2. 2025-02-24 16:50:08 +04:00
Alexander Shaduri b2912950c9 Fixed Windows CI packaging. v2.0.2 2025-02-24 16:08:36 +04:00
Alexander Shaduri af2e47308c Bumped version to 2.0.2. 2025-02-24 16:04:30 +04:00
Alexander Shaduri 37be3a413a Updated NEWS for 2.0.2 release. 2025-02-24 16:03:48 +04:00
Alexander Shaduri a7281b7b1e Document GCC 11 support. 2025-02-24 16:03:22 +04:00
Alexander Shaduri 23d06c4bc7 Cleanup. 2025-02-24 16:03:02 +04:00
Alexander Shaduri b5f522d8bc Fix OBS repository list. 2025-02-24 14:56:14 +04:00
Alexander Shaduri 283792715c Update CI to use GCC14. 2025-02-24 14:03:40 +04:00
Alexander Shaduri d7032eb351 Allow smartctl < 7.3 again, falling back to Text parser; this configuration is for compatibility only and not fully supported. 2025-02-24 13:52:04 +04:00
Alexander Shaduri 589c280bdc Support saving smartctl output to text (using old text format) instead of json (#76). 2025-02-15 13:22:47 +04:00
Alexander Shaduri 9f85d09736 Support standard (non-extended) self-test log in JSON ATA parser (#79). 2025-02-14 13:48:30 +04:00
Alexander Shaduri d45e5360cc Temperature: Fixed reporting unreasonably large values when raw value encodes min/max values as well (#78); support protocol-independent temperature reporting in JSON. 2025-02-14 13:28:43 +04:00
Alexander Shaduri 58d2a8b58f Windows: Use older librsvg in CI to support Windows 7 (#71). 2025-02-13 17:11:33 +04:00
Alexander Shaduri d51820476b Windows: Use older librsvg in CI to support Windows 7 (#71). 2025-02-13 16:35:55 +04:00
Alexander Shaduri bfce801cc5 Windows: Use older librsvg in CI to support Windows 7 (#71). 2025-02-13 16:30:36 +04:00
Alexander Shaduri 63f32e4d8b Windows: Use older librsvg in CI to support Windows 7 (#71). 2025-02-13 16:25:47 +04:00
Alexander Shaduri 0fc5d208bb Support Ubuntu 22.04 in CI. 2025-02-07 13:00:29 +04:00
Alexander Shaduri 8b3b500034 Support Ubuntu 22.04 in CI. 2025-02-07 11:51:13 +04:00
Alexander Shaduri a5fddf1bb2 Use {fmt} instead of <format> to support older compilers. 2025-02-07 11:44:50 +04:00