Skip to content

Re-add min width to button in new enty dialog#14791

Merged
Siedlerchr merged 3 commits intomainfrom
readdMInWidthPrefSize
Jan 12, 2026
Merged

Re-add min width to button in new enty dialog#14791
Siedlerchr merged 3 commits intomainfrom
readdMInWidthPrefSize

Conversation

@Siedlerchr
Copy link
Member

@Siedlerchr Siedlerchr commented Jan 3, 2026

User description

Try to fix #14789

Steps to test

Mandatory checks


PR Type

Bug fix


Description

  • Restores minimum width constraint to entry type buttons

  • Prevents buttons from shrinking below preferred size

  • Adds Region import for USE_PREF_SIZE constant


Diagram Walkthrough

flowchart LR
  A["NewEntryView.java"] -->|Add Region import| B["Import javafx.scene.layout.Region"]
  A -->|Set button constraints| C["button.setMinWidth<br/>Region.USE_PREF_SIZE"]
  C -->|Prevents shrinking| D["Button layout fixed"]
Loading

File Walkthrough

Relevant files
Bug fix
NewEntryView.java
Add minimum width constraint to entry buttons                       

jabgui/src/main/java/org/jabref/gui/newentry/NewEntryView.java

  • Added import for javafx.scene.layout.Region class
  • Added button.setMinWidth(Region.USE_PREF_SIZE) to prevent buttons from
    shrinking below their preferred size
  • Applied constraint in addEntriesToPane() method when creating entry
    type buttons
+2/-0     

@Siedlerchr Siedlerchr added the dev: binaries Binary builds should be uploaded to builds.jabref.org label Jan 3, 2026
@qodo-free-for-open-source-projects
Copy link
Contributor

qodo-free-for-open-source-projects bot commented Jan 3, 2026

PR Compliance Guide 🔍

Below is a summary of compliance checks for this PR:

Security Compliance
🟢
No security concerns identified No security vulnerabilities detected by AI analysis. Human verification advised for critical code.
Ticket Compliance
🟡
🎫 #14789
🟢 Recommended-type buttons should not reflow due to reduced width (e.g., "Misc" should not
shift position)
The "New Entry" dialog should open with the same default size/geometry as before the
change in PR
No major or unexpected shrink should occur that leaves large unused space
The dialog should not open substantially narrower than before
After clicking "Other types", the layout should not become crowded due to increased number
of options
🟡
🎫 #13109
🔴 Pseudonymization functionality should be available on the CLI
Implementation should provide similar CLI experience to consistency check
Implementation should follow the pattern of CheckConsistency class
Codebase Duplication Compliance
Codebase context is not defined

Follow the guide to enable codebase context checks.

Custom Compliance
🟢
Generic: Comprehensive Audit Trails

Objective: To create a detailed and reliable record of critical system actions for security analysis
and compliance.

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Meaningful Naming and Self-Documenting Code

Objective: Ensure all identifiers clearly express their purpose and intent, making code
self-documenting

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Robust Error Handling and Edge Case Management

Objective: Ensure comprehensive error handling that provides meaningful context and graceful
degradation

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Secure Error Handling

Objective: To prevent the leakage of sensitive system information through error messages while
providing sufficient detail for internal debugging.

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Secure Logging Practices

Objective: To ensure logs are useful for debugging and auditing without exposing sensitive
information like PII, PHI, or cardholder data.

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

Generic: Security-First Input Validation and Data Handling

Objective: Ensure all data inputs are validated, sanitized, and handled securely to prevent
vulnerabilities

Status: Passed

Learn more about managing compliance generic rules or creating your own custom rules

  • Update
Compliance status legend 🟢 - Fully Compliant
🟡 - Partial Compliant
🔴 - Not Compliant
⚪ - Requires Further Human Verification
🏷️ - Compliance label

@qodo-free-for-open-source-projects
Copy link
Contributor

qodo-free-for-open-source-projects bot commented Jan 3, 2026

PR Code Suggestions ✨

Explore these optional code suggestions:

CategorySuggestion                                                                                                                                    Impact
Learned
best practice
Fix method name capitalization

The method name contains a typo: 'Bibtex' should be 'BibTeX' to match the
correct capitalization used elsewhere in the codebase and in the field's
standard naming convention.

jabgui/src/main/java/org/jabref/gui/newentry/NewEntryView.java [447]

-private void switchSpecifyBibtex() {
+private void switchSpecifyBibTeX() {

[To ensure code accuracy, apply this suggestion manually]

Suggestion importance[1-10]: 6

__

Why:
Relevant best practice - Correct typographical errors in user-facing strings, code comments, and method names to maintain code quality and professionalism

Low
  • Update

@github-actions
Copy link
Contributor

github-actions bot commented Jan 5, 2026

The build of this PR is available at https://builds.jabref.org/pull/14791/merge.

@Siedlerchr Siedlerchr enabled auto-merge January 12, 2026 21:29
@Siedlerchr Siedlerchr disabled auto-merge January 12, 2026 21:30
@Siedlerchr Siedlerchr merged commit 1a3f828 into main Jan 12, 2026
52 checks passed
@Siedlerchr Siedlerchr deleted the readdMInWidthPrefSize branch January 12, 2026 21:30
@subhramit subhramit changed the title Readd min width to button in new enty dialog Re-add min width to button in new enty dialog Jan 12, 2026
Siedlerchr added a commit to st-rm-ng/jabref that referenced this pull request Jan 17, 2026
* upstream/main: (64 commits)
  New Crowdin updates (JabRef#14862)
  Make JDK25 available (JabRef#14861)
  Fix empty entries array when exporting group chat to JSON (JabRef#14814)
  feat: add right-click copy context menu to AI chat messages (JabRef#14722)
  FIX : generic error dialog and icon in Source Tab parsing (JabRef#14828)
  Factor out setup-* actions (JabRef#14859)
  Link .http files.
  Update dependency org.postgresql:postgresql to v42.7.9 (JabRef#14857)
  Add more commands to JabSrv (JabRef#14855)
  Fix JabRef#14821: Hide identifier action buttons when field is empty (JabRef#14831)
  Add GH_TOKEN to closed issues/PRs processing step
  New Crowdin updates (JabRef#14854)
  New Crowdin updates (JabRef#14849)
  Chore(deps): Bump jablib/src/main/resources/csl-styles from `0201999` to `f345aa8` (JabRef#14833)
  Add support for book front covers, again (JabRef#14777)
  Readd min width to button in new enty dialog (JabRef#14791)
  Replace plugin impl from jbang plugin (JabRef#14846)
  Revise AI policy wording
  Chore(deps): Bump jablib/src/main/resources/csl-locales (JabRef#14677)
  Update dependency com.konghq:unirest-modules-gson to v4.7.1 (JabRef#14845)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dev: binaries Binary builds should be uploaded to builds.jabref.org Review effort 1/5

Projects

None yet

Development

Successfully merging this pull request may close these issues.

New Entry dialog default size/layout changed significantly (much narrower)

1 participant