Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ Note that this project **does not** adhere to [Semantic Versioning](https://semv
- We fixed an issue where the "Get fulltext" button showed no progress during "Search full text documents online". [#17224](https://github.com/JabRef/jabref/pull/17224)
- We fixed an issue where searching with a full DOI link returned no results. [#17348](https://github.com/JabRef/jabref/issues/17348)
- We fixed an issue where the consistency check reported missing linked files as an inconsistency. [#17309](https://github.com/JabRef/jabref/issues/17309)
- We reduced the flickering of the entry editor when switching between entries with groups or keywords. [#17229](https://github.com/JabRef/jabref/issues/17229)

### Removed

Expand Down
24 changes: 24 additions & 0 deletions jabgui/src/main/java/org/jabref/gui/fieldeditors/TagsEditor.java
Original file line number Diff line number Diff line change
Expand Up @@ -254,6 +254,30 @@ private Node createTag(Keyword tag) {
protected void customizeTag(Label tagLabel, Keyword tag) {
}

/// While the [#tagsField] has no width yet, GemsFX's `FlowPane` puts every tag on its own row,
/// so the first layout pass would reserve one row per tag. The height then drops once the real width is known,
/// which makes the editor flicker. Until the field has a width, report the height of a single row instead.
/// Both the minimum and the preferred height are overridden because the grid uses the larger of the two.
private double singleRowHeight() {
return snappedTopInset() + tagsField.prefHeight(-1) + snappedBottomInset();
}

@Override
protected double computeMinHeight(double width) {
if (tagsField.getWidth() <= 0) {
return singleRowHeight();
}
return super.computeMinHeight(width);
}

@Override
protected double computePrefHeight(double width) {
if (tagsField.getWidth() <= 0) {
return singleRowHeight();
}
return super.computePrefHeight(width);
}

@Override
public Parent getNode() {
return this;
Expand Down
Loading