Skip to content

Change the default values in the new UI#361

Merged
kwart merged 1 commit intomasterfrom
claude/cb-defaults
Apr 21, 2026
Merged

Change the default values in the new UI#361
kwart merged 1 commit intomasterfrom
claude/cb-defaults

Conversation

@kwart
Copy link
Copy Markdown
Member

@kwart kwart commented Apr 21, 2026

Summary

  • Append signature and Store passwords checkboxes in the JavaFX UI are now checked by default on fresh installs. Previously both defaulted to unchecked, despite DEFVAL_APPEND=true existing in Constants.
  • Root cause: BasicSignerOptions.loadOptions() called getAsBool(key) without a default, so missing keys silently resolved to false and overrode the field's initial value. Fixed by passing DEFVAL_APPEND / new DEFVAL_STOREPWD as fallbacks.
  • CLI behavior is unaffected: the -a flag always overrides append, and storePasswords is not used by the CLI flows.
  • Users with existing ~/.JSignPdf preferences keep their saved values — both keys are always persisted by storeOptions(), so only truly fresh installs (or post "Reset Settings") see the new defaults.

Test plan

  • New unit tests in BasicSignerOptionsTest: default field values, loadOptions() with empty props, explicit-false preserved.
  • SigningOptionsViewModelTest: new fresh-VM defaults test; updated resetToDefaults expectation for storePasswords.
  • mvn -pl jsignpdf test — 110 tests pass.
  • Manual smoke check: launch JavaFX UI with no ~/.JSignPdf; verify both checkboxes start checked.
  • Manual smoke check: uncheck both, close, relaunch; verify the unchecked state is restored.

Docs

  • website/docs/JSignPdf.adoc — Append signature and Remember passwords sections updated.
  • distribution/doc/release-notes/3.0.0.md — bullet added.

@kwart kwart merged commit c578f82 into master Apr 21, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant