From 57fa3d92dd08f90102df90e9493ac3c7109248cb Mon Sep 17 00:00:00 2001 From: Alhan Date: Tue, 20 Oct 2026 23:09:13 +0300 Subject: [PATCH] feat: settings version display, complete shortcut list, Ctrl fine zoom (v1.7.0) --- README.md | 8 ++++++-- lib/l10n/app_en.arb | 2 +- lib/l10n/app_localizations.dart | 2 +- lib/l10n/app_localizations_en.dart | 2 +- lib/l10n/app_localizations_tr.dart | 2 +- lib/l10n/app_tr.arb | 2 +- lib/screens/viewer_screen.dart | 5 ++++- lib/widgets/image_canvas.dart | 2 +- pubspec.yaml | 2 +- 9 files changed, 17 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 475959c..eaccd10 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,8 @@ Ultra-lightweight image viewer written in Flutter — Linux & Windows. - **Formats:** PNG, JPEG, JFIF, WebP, BMP, GIF, WBMP - **Pan:** Left drag -- **Zoom:** Mouse wheel (cursor-centered; viewport-centered in rotate mode) +- **Zoom:** Mouse wheel — 10% per step, cursor-centered (viewport-centered in rotate mode); + hold `Ctrl` for fine zoom (1% per step) - **Fill/Fit toggle:** Double left click - **Contrast:** Right drag + vertical move - **Saturation:** Ctrl + Right drag + vertical move @@ -83,7 +84,8 @@ folder including `imajviewer.exe` and all DLLs). | Interaction | Action | |---|---| | Left drag | Pan | -| Mouse wheel | Zoom (cursor-centered) | +| Mouse wheel | Zoom (cursor-centered, 10% per step) | +| Ctrl + Mouse wheel | Fine zoom (1% per step) | | Double left click | Fill / Fit toggle | | Right drag + vertical | Contrast (0.0 – 2.0) | | Ctrl + Right drag + vertical | Saturation (0.0 – 2.0) | @@ -92,7 +94,9 @@ folder including `imajviewer.exe` and all DLLs). | Ctrl + R | Flip horizontally (clears effects; press again to undo) | | Double right click | Reset (all effects) | | Left / Right arrow | Previous / next image | +| Ctrl + O | Open file | | Ctrl + S | Save visible area (JPEG 95, original resolution) | +| Esc | Exit fullscreen | | Ctrl + Q | Close window | | Ctrl + Shift + Q | Close all windows | diff --git a/lib/l10n/app_en.arb b/lib/l10n/app_en.arb index b257860..334481f 100644 --- a/lib/l10n/app_en.arb +++ b/lib/l10n/app_en.arb @@ -6,7 +6,7 @@ "sortByName": "By name", "appDescription": "Ultra-lightweight and fast image viewer. Open images and use arrows or keyboard keys to navigate.", "shortcuts": "Shortcuts", - "shortcutsList": "• Left/Right arrow — previous/next image\n• Ctrl+S — save visible area (JPEG 95)\n• Ctrl+R — flip horizontally (clears effects, press again to undo)\n• Ctrl+Q — close window\n• Ctrl+Shift+Q — close all windows\n• Double click — toggle fill/fit\n• Right-drag — contrast\n• Shift+right-drag — rotate\n• Ctrl+right-drag — saturation\n• Ctrl+Shift+right-drag — brightness", + "shortcutsList": "• Left/Right arrow — previous/next image\n• Ctrl+O — open file\n• Ctrl+S — save visible area (JPEG 95)\n• Ctrl+R — flip horizontally (clears effects, press again to undo)\n• Ctrl+Q — close window\n• Ctrl+Shift+Q — close all windows\n• Esc — exit fullscreen\n• Scroll — zoom (10% per step)\n• Ctrl+scroll — fine zoom (1% per step)\n• Left-drag — pan\n• Double click — toggle fill/fit\n• Right double click — reset effects\n• Right-drag — contrast\n• Shift+right-drag — rotate\n• Ctrl+right-drag — saturation\n• Ctrl+Shift+right-drag — brightness", "print": "Print", "close": "Close", "saveCrop": "Save visible area (JPEG 95)", diff --git a/lib/l10n/app_localizations.dart b/lib/l10n/app_localizations.dart index 9989f24..e1c589a 100644 --- a/lib/l10n/app_localizations.dart +++ b/lib/l10n/app_localizations.dart @@ -137,7 +137,7 @@ abstract class AppLocalizations { /// No description provided for @shortcutsList. /// /// In en, this message translates to: - /// **'• Left/Right arrow — previous/next image\n• Ctrl+S — save visible area (JPEG 95)\n• Ctrl+R — flip horizontally (clears effects, press again to undo)\n• Ctrl+Q — close window\n• Ctrl+Shift+Q — close all windows\n• Double click — toggle fill/fit\n• Right-drag — contrast\n• Shift+right-drag — rotate\n• Ctrl+right-drag — saturation\n• Ctrl+Shift+right-drag — brightness'** + /// **'• Left/Right arrow — previous/next image\n• Ctrl+O — open file\n• Ctrl+S — save visible area (JPEG 95)\n• Ctrl+R — flip horizontally (clears effects, press again to undo)\n• Ctrl+Q — close window\n• Ctrl+Shift+Q — close all windows\n• Esc — exit fullscreen\n• Scroll — zoom (10% per step)\n• Ctrl+scroll — fine zoom (1% per step)\n• Left-drag — pan\n• Double click — toggle fill/fit\n• Right double click — reset effects\n• Right-drag — contrast\n• Shift+right-drag — rotate\n• Ctrl+right-drag — saturation\n• Ctrl+Shift+right-drag — brightness'** String get shortcutsList; /// No description provided for @print. diff --git a/lib/l10n/app_localizations_en.dart b/lib/l10n/app_localizations_en.dart index bb14b06..f7513d8 100644 --- a/lib/l10n/app_localizations_en.dart +++ b/lib/l10n/app_localizations_en.dart @@ -29,7 +29,7 @@ class AppLocalizationsEn extends AppLocalizations { @override String get shortcutsList => - '• Left/Right arrow — previous/next image\n• Ctrl+S — save visible area (JPEG 95)\n• Ctrl+R — flip horizontally (clears effects, press again to undo)\n• Ctrl+Q — close window\n• Ctrl+Shift+Q — close all windows\n• Double click — toggle fill/fit\n• Right-drag — contrast\n• Shift+right-drag — rotate\n• Ctrl+right-drag — saturation\n• Ctrl+Shift+right-drag — brightness'; + '• Left/Right arrow — previous/next image\n• Ctrl+O — open file\n• Ctrl+S — save visible area (JPEG 95)\n• Ctrl+R — flip horizontally (clears effects, press again to undo)\n• Ctrl+Q — close window\n• Ctrl+Shift+Q — close all windows\n• Esc — exit fullscreen\n• Scroll — zoom (10% per step)\n• Ctrl+scroll — fine zoom (1% per step)\n• Left-drag — pan\n• Double click — toggle fill/fit\n• Right double click — reset effects\n• Right-drag — contrast\n• Shift+right-drag — rotate\n• Ctrl+right-drag — saturation\n• Ctrl+Shift+right-drag — brightness'; @override String get print => 'Print'; diff --git a/lib/l10n/app_localizations_tr.dart b/lib/l10n/app_localizations_tr.dart index 8c7a8d0..cad12c7 100644 --- a/lib/l10n/app_localizations_tr.dart +++ b/lib/l10n/app_localizations_tr.dart @@ -29,7 +29,7 @@ class AppLocalizationsTr extends AppLocalizations { @override String get shortcutsList => - '• Sol/Sağ ok — önceki/sonraki resim\n• Ctrl+S — görünen alanı kaydet (JPEG 95)\n• Ctrl+R — yatay aynala (efektleri sıfırlar, tekrar basınca geri alır)\n• Ctrl+Q — pencereyi kapat\n• Ctrl+Shift+Q — tüm pencereleri kapat\n• Çift tık — doldur/sığdır geçişi\n• Sağ tık sürükle — kontrast\n• Shift+sağ tık — döndür\n• Ctrl+sağ tık — doygunluk\n• Ctrl+Shift+sağ tık — parlaklık'; + '• Sol/Sağ ok — önceki/sonraki resim\n• Ctrl+O — dosya aç\n• Ctrl+S — görünen alanı kaydet (JPEG 95)\n• Ctrl+R — yatay aynala (efektleri sıfırlar, tekrar basınca geri alır)\n• Ctrl+Q — pencereyi kapat\n• Ctrl+Shift+Q — tüm pencereleri kapat\n• Esc — tam ekrandan çık\n• Kaydırma — yakınlaştır (tık başına %10)\n• Ctrl+kaydırma — ince yakınlaştırma (tık başına %1)\n• Sol tık sürükle — kaydır\n• Çift tık — doldur/sığdır geçişi\n• Sağ çift tık — efektleri sıfırla\n• Sağ tık sürükle — kontrast\n• Shift+sağ tık — döndür\n• Ctrl+sağ tık — doygunluk\n• Ctrl+Shift+sağ tık — parlaklık'; @override String get print => 'Yazdır'; diff --git a/lib/l10n/app_tr.arb b/lib/l10n/app_tr.arb index b8fcfeb..9e65ec5 100644 --- a/lib/l10n/app_tr.arb +++ b/lib/l10n/app_tr.arb @@ -6,7 +6,7 @@ "sortByName": "İsme göre", "appDescription": "Ultra hafif ve hızlı resim görüntüleyici. Görselleri açın, gezinti için okları veya klavye tuşlarını kullanın.", "shortcuts": "Kısayollar", - "shortcutsList": "• Sol/Sağ ok — önceki/sonraki resim\n• Ctrl+S — görünen alanı kaydet (JPEG 95)\n• Ctrl+R — yatay aynala (efektleri sıfırlar, tekrar basınca geri alır)\n• Ctrl+Q — pencereyi kapat\n• Ctrl+Shift+Q — tüm pencereleri kapat\n• Çift tık — doldur/sığdır geçişi\n• Sağ tık sürükle — kontrast\n• Shift+sağ tık — döndür\n• Ctrl+sağ tık — doygunluk\n• Ctrl+Shift+sağ tık — parlaklık", + "shortcutsList": "• Sol/Sağ ok — önceki/sonraki resim\n• Ctrl+O — dosya aç\n• Ctrl+S — görünen alanı kaydet (JPEG 95)\n• Ctrl+R — yatay aynala (efektleri sıfırlar, tekrar basınca geri alır)\n• Ctrl+Q — pencereyi kapat\n• Ctrl+Shift+Q — tüm pencereleri kapat\n• Esc — tam ekrandan çık\n• Kaydırma — yakınlaştır (tık başına %10)\n• Ctrl+kaydırma — ince yakınlaştırma (tık başına %1)\n• Sol tık sürükle — kaydır\n• Çift tık — doldur/sığdır geçişi\n• Sağ çift tık — efektleri sıfırla\n• Sağ tık sürükle — kontrast\n• Shift+sağ tık — döndür\n• Ctrl+sağ tık — doygunluk\n• Ctrl+Shift+sağ tık — parlaklık", "print": "Yazdır", "close": "Kapat", "saveCrop": "Görünen alanı kaydet (JPEG 95)", diff --git a/lib/screens/viewer_screen.dart b/lib/screens/viewer_screen.dart index 7406cec..ec0dc86 100644 --- a/lib/screens/viewer_screen.dart +++ b/lib/screens/viewer_screen.dart @@ -16,6 +16,8 @@ import '../shortcuts/app_shortcuts.dart'; import '../services/window_persistence.dart'; import '../l10n/app_localizations.dart'; +const appVersion = '1.7.0'; + class ViewerScreen extends StatefulWidget { final List initialFiles; const ViewerScreen({super.key, this.initialFiles = const []}); @@ -132,7 +134,8 @@ class _ViewerScreenState extends State with WindowListener { }, ), const Divider(color: Colors.white24, height: 24), - const Text('imajViewer', style: TextStyle(color: Colors.white, fontSize: 15)), + Text('imajViewer $appVersion', + style: const TextStyle(color: Colors.white, fontSize: 15)), const SizedBox(height: 4), Text( AppLocalizations.of(context)!.appDescription, diff --git a/lib/widgets/image_canvas.dart b/lib/widgets/image_canvas.dart index d0411e3..f00f354 100644 --- a/lib/widgets/image_canvas.dart +++ b/lib/widgets/image_canvas.dart @@ -233,7 +233,7 @@ class ImageCanvasState extends State { final double vy = _angle == 0 ? e.localPosition.dy : _vpSize.height / 2; final double cx = (vx - _tx) / _sc; final double cy = (vy - _ty) / _sc; - const double factor = 1.1; + final double factor = _ctrlPressed ? 1.01 : 1.1; final double rawSc = _sc * (e.scrollDelta.dy < 0 ? factor : 1.0 / factor); final double newSc = rawSc.clamp(1.0, 20.0); if (_angle == 0) { diff --git a/pubspec.yaml b/pubspec.yaml index 89f1d3d..012da15 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,7 +1,7 @@ name: imajviewer description: "Ultra-lightweight image viewer for Linux and Windows." publish_to: 'none' -version: 1.6.3+15 +version: 1.7.0+16 msix_config: display_name: ImajViewer