27 Commits

Author SHA1 Message Date
Mahmoud Ben Hassine
8f4e1b78fa Update test dependencies for the latest Spring Boot 3.5 snapshots
Spring Boot 3.5 updated JUnit Jupiter from v5.11 to v5.12.
With this new version, the junit-platform-launcher dependency
must be declared explicitly.
2025-04-22 20:04:09 +02:00
Janne Valkealahti
2b18de0ffb Fix fg and bg styling
- In ListView and MenuView fix how styling for
  background and foreground are used.
- In Catalog app fix same issue in ScenarioListCell
- Fixes #1063
2024-05-07 08:05:45 +01:00
Janne Valkealahti
192eb5e506 Add ProgressView initial scenario
- Relates #995
2024-02-16 17:53:21 +00:00
Janne Valkealahti
7c91dbff8a Scenario lifecycle methods
- Add ScenarioContext which knows about View and start/stop
  runnable methods.
- Change Catalog to rely on ScenarioContext and call
  start/stop on an appropriate moment.
- Still keep Scenario.build() around so that we have time
  to refactor in favour of ScenarioContext.buildContext()
  or whatever build() method in it should be.
- Fixes #1004
2024-02-16 17:53:03 +00:00
Janne Valkealahti
2d29050c34 Make Catalog browsers focusable with shortcuts
- Category and scenario list views can now be focused with
  ctrl+a/ctrl+s.
- Bind all keys with ctrl modifier
- Add "shortcut" concept to views which currently hooks to
  hot keys.
- In a catalog app by using a "shortcut" then takes the key
  event as a hot key, as it consumes resulting behaviour
  is to focus.
- Move view initInternal away from constructor call to
  require user to call init() which is not in a
  View interface
- Relates #826
2023-11-12 16:43:11 +00:00
Janne Valkealahti
ccf6d771d9 Add multiinput scenario
- InputView using viewcommands and has event for text change.
- Experimental way to handle tab navigation in a layout views.
- New viewcommands for tab navigation and moving cursor.
- Mouse click takes focus in AbstractView if no view command
  binding.
- MultiInputViewScenario now shows tab navigation.
- Fixes #917
2023-11-07 08:26:43 +00:00
Janne Valkealahti
bba7a82ab4 Make StatusBarView work with hotkeys
- StatusItem can now define a hotkey which is then
  bound to its action.
- In catalog app replace use of raw key event to
  item's hotkey for status bar visibility.
- Various doc updates.
- Relates #826
2023-10-30 09:31:03 +00:00
Janne Valkealahti
82df453cc0 Autoconfigure TerminalUI
- Add TerminalUIBuilder which can be used to build TerminalUI
- Add TerminalUICustomizer which can customize TerminalUI
- What is autoconfigured is TerminalUIBuilder.
- In TerminalUI add configure for views which now allows
  easier way to set needed stuff in views.
- Various changes in a catalog app
- Fixes #900
2023-10-25 09:10:42 +01:00
Janne Valkealahti
92eb7dd2b7 Relocate message package from view
- Relates #813
2023-10-20 08:48:36 +01:00
Janne Valkealahti
433c1f96f0 Relocate geom package from view
- Relates #813
2023-10-20 08:38:01 +01:00
Janne Valkealahti
8de0ef47df Better background handling in themes
- Modify view structures so that we're able to
  control background drawing better
- Remove transparent concept from box view
- Add background styles for dialog, menu/status bars
- Relates #824
2023-10-19 13:12:42 +01:00
Janne Valkealahti
52b242dcbf Polish scenario descriptions 2023-10-13 14:07:59 +01:00
Janne Valkealahti
da529fa277 Make samples native build fully optional
- Add springShellSampleNative project property
- Implement generic samples build logic in buildSrc
- Fixes #873
2023-09-24 08:37:32 +01:00
Janne Valkealahti
51c250608b Overhaul ListView to support checked states
- ListView can be defined to use nocheck, checked or radio
- List can now scroll through up/down
- Actual visual is handled in a DefaultListCell
- Modify/add scenarios and catalog app
- Relates #865
2023-09-09 08:59:37 +03:00
Janne Valkealahti
aa3c580220 Move interrupt message to ShellMessageBuilder
- Relates #761
2023-08-30 09:19:35 +03:00
Janne Valkealahti
ba5ab1a463 Dialog should float
- New WindowView which can be partially atop of background.
- DialogView now extends WindowView
- Change dialog in Catalog sample and Dialog scenario
- Relates #825
- Relates #855
2023-08-24 20:02:53 +03:00
Janne Valkealahti
88c1f56c71 Add about dialog to catalog app
- Relates #825
2023-08-24 08:46:09 +03:00
Janne Valkealahti
29417d495b Initial modal integration
- Integrate TerminalUI to ViewService and modals
- New Dialog scenario
- Relates #825
2023-08-21 09:37:05 +03:00
Janne Valkealahti
7391d0d24f Initial hotkey infra
- Duplicate keyhandler into hotkeyhandler
- Define some view to handle hot keys, like AppView and MenuBarView
- Catalog app binds some menus to hot keys
- Bind all normal keys a-z with alt
- Relates #823
- Relates #826
2023-08-10 08:27:49 +01:00
Janne Valkealahti
ef713638b2 Base theming for views
- Control is now aware of active theme name and resolver.
- Theme some settings in BoxView, ListView and MenuView.
- Overhaul scenario system to make it work with themes.
- Add new "background" StyleSetting.
- Relates #824
2023-08-04 14:19:33 +01:00
Greg Cooper
c5145a2fe6 Do not include timestamp for buildInfo. 2023-08-02 08:51:35 +01:00
Janne Valkealahti
3a2d7d4817 Restore focus after returning from scenario
- Relates #811
2023-07-22 17:27:21 +01:00
Janne Valkealahti
4b927be807 Hide statusbar in a catalog app
- Can clear items from a GridView
- Full refactor for AppView now using GridView internally
  and can hide/show menu/status.
- Add function key bindings f1-f10
- Modify catalog app to use new features in an AppView, listen
  F10 key to toggle statusbar visibility.
- Relates #805
- Relates #807
- Relates #811
2023-07-22 14:21:10 +01:00
Janne Valkealahti
c074af314b Add focused color and style for BoxView title
- May define focused color and style for title
  which overrides normal color and style if set.
- Use these in a catalog app.
- Relates #804
2023-07-21 09:26:31 +01:00
Janne Valkealahti
748f41103d Fix removed deprecation
- Fix property values which doesn't exist in gradle zip task anymore.
- Relates #821
2023-07-21 08:09:24 +01:00
Janne Valkealahti
a0bdbfc033 Initial terminal ui implementation
- This commit adds proof of concept work for terminal ui as is.
- Some things work, some don't but we need to start from somewhere.
  Further development continues in a main.
- Essentially we are starting to have enough so that it merits to
  move all this work into a main repo.
- Everything new is kept under org.springframework.shell.component.view
  and will get revisiter later to find correct locations for some classes.
- Catalog sample has been modified to provide "showcase" app for
  terminal ui features. This is a start while it already contains
  some usefull scenarios.
- Relates #800
- Relates #801
- Relates #802
- Relates #803
- Relates #804
- Relates #805
- Relates #806
- Relates #807
- Relates #808
- Relates #809
- Relates #810
- Relates #811
2023-07-15 16:42:39 +01:00
Janne Valkealahti
625619fc92 Add primary command sample
- New spring-shell-sample-catalog which is a skeleton meant for
  future view overhaul work.
- Relates #755
2023-07-05 10:35:30 +01:00