Commit graph

1 commit

Author SHA1 Message Date
c965472ac5 feat: Add fully interactive browsing with scrolling and link navigation
Implemented complete interactive browser experience with keyboard-driven
navigation.

Interactive Features Added:
 Content Scrolling
  - j/k or arrow keys: Line-by-line scrolling
  - Space/b or PageUp/PageDown: Page scrolling
  - g/G: Jump to top/bottom
  - Real-time scroll position indicator

 Link Navigation
  - Tab/Shift+Tab: Cycle through links
  - 1-9 number keys: Jump directly to links
  - Enter: Follow selected link
  - Selected link highlighted in status bar

 Browser Navigation
  - Back/forward button state (dimmed when unavailable)
  - Backspace: Go back in history
  - r/F5: Refresh page
  - o: Open address bar to enter new URL

 Enhanced UI
  - Status panel shows load stats (KB, time, link count)
  - Selected link URL shown in status bar
  - Scroll position indicator
  - Navigation button states

Technical Implementation:
- Rewrote MainWindow with full FTXUI event handling
- Implemented content line splitting for scrolling
- Added link selection state management
- Wired up browser engine callbacks
- Added timing and statistics tracking
- Proper back/forward history support

Files Modified:
- src/ui/main_window.cpp - Complete rewrite with interactive features
- src/main.cpp - Wire up all callbacks and link handling
- KEYBOARD.md - Complete keyboard shortcuts reference

Tested with:
https://tldp.org/HOWTO/HOWTO-INDEX/howtos.html
https://example.com

The browser is now fully interactive and usable for real web browsing! 🎉
2025-12-31 17:50:15 +08:00