Skip to content

Commit c84be95

Browse files
committed
Merge remote-tracking branch 'upstream/master' into replace_deprecated
# Conflicts: # src/main/java/org/jabref/gui/JabRefFrame.java
2 parents 9b8e385 + d38f813 commit c84be95

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+567
-838
lines changed

.sonarcloud.properties

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+

CHANGELOG.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ We refer to [GitHub issues](https://github.com/JabRef/jabref/issues) by using `#
1313

1414
### Changed
1515

16-
- We reintroduced the possibility to extract references from plain text (using GROBID) [#5614](https://github.com/JabRef/jabref/pull/5614)
16+
- We reintroduced the possibility to extract references from plain text (using GROBID) [#5614](https://github.com/JabRef/jabref/pull/5614)
1717
- We changed the open office panel to show buttons in rows of three instead of going straight down to save space as the button expanded out to take up unnecessary horizontal space. [#5479](https://github.com/JabRef/jabref/issues/5479)
1818
- We cleaned up the group add/edit dialog. [#5826](https://github.com/JabRef/jabref/pull/5826)
1919
- We reintroduced the index column. [#5844](https://github.com/JabRef/jabref/pull/5844)
@@ -37,8 +37,14 @@ We refer to [GitHub issues](https://github.com/JabRef/jabref/issues) by using `#
3737
- We fixed several issues concerning managing external file types: Now everything is usable and fully functional. Previously, there were problems with the radio buttons, with saving the settings and with loading an input field value. Furthermore, different behavior for Windows and other operating systems was given, which was unified as well. [#5846](https://github.com/JabRef/jabref/issues/5846)
3838
- We fixed an issue where entries containing Unicode charaters were not parsed correctly [#5899](https://github.com/JabRef/jabref/issues/5899)
3939
- We fixed an issue where an entry containing an external filename with curly braces could not be saved. Curly braces are now longer allowed in filenames. [#5899](https://github.com/JabRef/jabref/issues/5899)
40+
- We fixed an issue where changing the type of an entry did not update the main table [#5906](https://github.com/JabRef/jabref/issues/5906)
41+
- We fixed an issue where opening a library from the recent libraries menu was not possible [#5939](https://github.com/JabRef/jabref/issues/5939)
42+
- We fixed an issue in the optics of the library properties, that cropped the dialog on scaled displays. [#5969](https://github.com/JabRef/jabref/issues/5969)
4043
- We fixed an issue where changing the type of an entry did not update the main table. [#5906](https://github.com/JabRef/jabref/issues/5906)
4144
- We fixed an issue where opening a library from the recent libraries menu was not possible. [#5939](https://github.com/JabRef/jabref/issues/5939)
45+
- We fixed an issue where the most bottom group in the list got lost, if it was dragged on itself. [#5983](https://github.com/JabRef/jabref/issues/5983)
46+
- We fixed an issue where changing entry type doesn't always work when biblatex source is shown. [#5905](https://github.com/JabRef/jabref/issues/5905)
47+
- We fixed an issue where the group and the link column were not updated after changing the entry in the main table. [#5985](https://github.com/JabRef/jabref/issues/5985)
4248

4349
### Removed
4450

buildres/windows/JabRefHost.ps1

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ function Respond($response) {
1111
}
1212
}
1313

14-
$jabRefExe = [System.IO.Path]::Combine($PSScriptRoot, "JabRef.exe")
14+
$jabRefExe = [System.IO.Path]::Combine($PSScriptRoot, "runtime\\bin\\JabRef.bat")
1515

1616
try {
1717
$reader = New-Object System.IO.BinaryReader([System.Console]::OpenStandardInput())
@@ -37,9 +37,10 @@ try {
3737
#$wshell = New-Object -ComObject Wscript.Shell
3838
#$wshell.Popup($message.Text,0,"JabRef", 0x0 + 0x30)
3939

40-
$messageText = $message.Text
41-
$output = & $jabRefExe -importBibtex "$messageText" 2>&1
42-
#$output = & echoargs -importBibtex $messageText 2>&1
40+
$messageText = $message.Text.replace("`n"," ").replace("`r"," ")
41+
$output = & $jabRefExe -importBibtex "$messageText" *>&1
42+
#$output = "$messageText"
43+
#$wshell = New-Object -ComObject Wscript.Shell
4344
#$wshell.Popup($output,0,"JabRef", 0x0 + 0x30)
4445
return Respond @{message="ok";output="$output"}
4546
} finally {

docs/code-quality.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# Code Quality
2+
3+
We monitor the general source code quality at three places:
4+
5+
* [Teamscale](https://www.cqse.eu/de/produkte/teamscale/landing/) is a popular German product analyzing code quality. The analysis results are available at <https://demo.teamscale.com/dashboard.html#show//?id=kinnen%2FJabref%20Overview>.
6+
* [codacy](https://www.codacy.com/) is a hosted service to monitor code quality. The code quality analysis for JabRef is available at <https://www.codacy.com/app/simonharrer/jabref/dashboard>.
7+
* [codecov](https://codecov.io/) is a solution to check code coverage of test cases. The code coverage metrics for JabRef are available at <https://codecov.io/github/JabRef/jabref>.
8+
9+
We strongly recommend to read following two books on code quality:
10+
11+
* [Java by Comparison](java.by-comparison.com/) is a book by three JabRef developers which focuses on code improvements close to single statements. It is fast to read and one gains much information from each recommendation discussed in the book.
12+
* [Effective Java](https://www.oreilly.com/library/view/effective-java-3rd/9780134686097/) is the standard book for advanced Java programming. Did you know that `enum` is the [recommended way to enforce a singleton instance of a class](https://learning.oreilly.com/library/view/effective-java-3rd/9780134686097/ch2.xhtml#lev3)? Did you know that one should [refer to objects by their interfaces](https://learning.oreilly.com/library/view/effective-java-3rd/9780134686097/ch9.xhtml#lev64)?

docs/guidelines-for-setting-up-a-local-workspace.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
# Setup a local workspace
1+
# Set up a local workspace
22

33
This guide explains how to set up your environment for development of JabRef. It includes information about prerequisites, configuring your IDE, and running JabRef locally to verify your setup.
44

5-
For a complete step-by-step guide (using IntellJ as the IDE), have a look at the following video instructions:
5+
For a complete step-by-step guide for Linux using IntellJ IDEA as the IDE, have a look at the following video instructions:
66

7-
<p align="center">
8-
<a href="http://www.youtube.com/watch?v=FeQpygT0314"><img src="http://img.youtube.com/vi/FeQpygT0314/0.jpg" /></a>
9-
</p>
7+
<a href="https://youtu.be/JkFVJ6p0urw">
8+
<img src="https://img.youtube.com/vi/JkFVJ6p0urw/mqdefault.jpg" alt="JabRef development video tutorial"/>
9+
</a>
1010

1111
## Prerequisites
1212

src/main/java/org/jabref/gui/JabRefFrame.java

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -499,7 +499,7 @@ private Node createToolbar() {
499499
factory.createIconButton(StandardActions.GENERATE_CITE_KEYS, new OldDatabaseCommandWrapper(Actions.MAKE_KEY, this, stateManager)),
500500
factory.createIconButton(StandardActions.CLEANUP_ENTRIES, new OldDatabaseCommandWrapper(Actions.CLEANUP, this, stateManager)),
501501
new Separator(Orientation.VERTICAL),
502-
factory.createIconButton(StandardActions.FORK_ME, new OpenBrowserAction("https://github.com/JabRef/jabref")),
502+
factory.createIconButton(StandardActions.OPEN_GITHUB, new OpenBrowserAction("https://github.com/JabRef/jabref")),
503503
factory.createIconButton(StandardActions.OPEN_FACEBOOK, new OpenBrowserAction("https://www.facebook.com/JabRef/")),
504504
factory.createIconButton(StandardActions.OPEN_TWITTER, new OpenBrowserAction("https://twitter.com/jabref_org"))
505505
);
@@ -717,18 +717,23 @@ private MenuBar createMenu() {
717717

718718
new SeparatorMenuItem(),
719719

720+
factory.createMenuItem(StandardActions.REPLACE_ALL, new OldDatabaseCommandWrapper(Actions.REPLACE_ALL, this, stateManager)),
721+
factory.createMenuItem(StandardActions.GENERATE_CITE_KEYS, new OldDatabaseCommandWrapper(Actions.MAKE_KEY, this, stateManager)),
722+
723+
new SeparatorMenuItem(),
724+
720725
factory.createMenuItem(StandardActions.MANAGE_KEYWORDS, new ManageKeywordsAction(stateManager))
721726
);
722727

723728
if (Globals.prefs.getBoolean(JabRefPreferences.SPECIALFIELDSENABLED)) {
724729
edit.getItems().addAll(
730+
new SeparatorMenuItem(),
725731
SpecialFieldMenuItemFactory.createSpecialFieldMenuForActiveDatabase(SpecialField.RANKING, factory, undoManager),
726732
SpecialFieldMenuItemFactory.getSpecialFieldSingleItemForActiveDatabase(SpecialField.RELEVANCE, factory),
727733
SpecialFieldMenuItemFactory.getSpecialFieldSingleItemForActiveDatabase(SpecialField.QUALITY, factory),
728734
SpecialFieldMenuItemFactory.getSpecialFieldSingleItemForActiveDatabase(SpecialField.PRINTED, factory),
729735
SpecialFieldMenuItemFactory.createSpecialFieldMenuForActiveDatabase(SpecialField.PRIORITY, factory, undoManager),
730-
SpecialFieldMenuItemFactory.createSpecialFieldMenuForActiveDatabase(SpecialField.READ_STATUS, factory, undoManager),
731-
new SeparatorMenuItem()
736+
SpecialFieldMenuItemFactory.createSpecialFieldMenuForActiveDatabase(SpecialField.READ_STATUS, factory, undoManager)
732737
);
733738
}
734739

@@ -772,6 +777,9 @@ private MenuBar createMenu() {
772777
tools.getItems().addAll(
773778
factory.createMenuItem(StandardActions.PARSE_TEX, new ParseTexAction(stateManager)),
774779
factory.createMenuItem(StandardActions.NEW_SUB_LIBRARY_FROM_AUX, new NewSubLibraryAction(this, stateManager)),
780+
781+
new SeparatorMenuItem(),
782+
775783
factory.createMenuItem(StandardActions.FIND_UNLINKED_FILES, new FindUnlinkedFilesAction(this, stateManager)),
776784
factory.createMenuItem(StandardActions.WRITE_XMP, new WriteXMPAction(stateManager, dialogService)),
777785
factory.createMenuItem(StandardActions.COPY_LINKED_FILES, new CopyFilesAction(stateManager, this.getDialogService())),
@@ -783,8 +791,6 @@ private MenuBar createMenu() {
783791

784792
new SeparatorMenuItem(),
785793

786-
factory.createMenuItem(StandardActions.GENERATE_CITE_KEYS, new OldDatabaseCommandWrapper(Actions.MAKE_KEY, this, stateManager)),
787-
factory.createMenuItem(StandardActions.REPLACE_ALL, new OldDatabaseCommandWrapper(Actions.REPLACE_ALL, this, stateManager)),
788794
factory.createMenuItem(StandardActions.SEND_AS_EMAIL, new SendAsEMailAction(dialogService, stateManager)),
789795
pushToApplicationMenuItem,
790796

@@ -850,23 +856,19 @@ private MenuBar createMenu() {
850856

851857
new SeparatorMenuItem(),
852858

859+
factory.createMenuItem(StandardActions.DONATE, new OpenBrowserAction("https://donations.jabref.org")),
853860
factory.createMenuItem(StandardActions.SEARCH_FOR_UPDATES, new SearchForUpdateAction(Globals.BUILD_INFO, prefs.getVersionPreferences(), dialogService, Globals.TASK_EXECUTOR)),
854861
factory.createSubMenu(StandardActions.WEB_MENU,
855862
factory.createMenuItem(StandardActions.OPEN_WEBPAGE, new OpenBrowserAction("https://jabref.org/")),
856863
factory.createMenuItem(StandardActions.OPEN_BLOG, new OpenBrowserAction("https://blog.jabref.org/")),
857864
factory.createMenuItem(StandardActions.OPEN_FACEBOOK, new OpenBrowserAction("https://www.facebook.com/JabRef/")),
858865
factory.createMenuItem(StandardActions.OPEN_TWITTER, new OpenBrowserAction("https://twitter.com/jabref_org")),
866+
factory.createMenuItem(StandardActions.OPEN_GITHUB, new OpenBrowserAction("https://github.com/JabRef/jabref")),
859867

860868
new SeparatorMenuItem(),
861869

862-
factory.createMenuItem(StandardActions.FORK_ME, new OpenBrowserAction("https://github.com/JabRef/jabref")),
863870
factory.createMenuItem(StandardActions.OPEN_DEV_VERSION_LINK, new OpenBrowserAction("https://builds.jabref.org/master/")),
864-
factory.createMenuItem(StandardActions.OPEN_CHANGELOG, new OpenBrowserAction("https://github.com/JabRef/jabref/blob/master/CHANGELOG.md")),
865-
866-
new SeparatorMenuItem(),
867-
868-
factory.createMenuItem(StandardActions.DONATE, new OpenBrowserAction("https://donations.jabref.org"))
869-
871+
factory.createMenuItem(StandardActions.OPEN_CHANGELOG, new OpenBrowserAction("https://github.com/JabRef/jabref/blob/master/CHANGELOG.md"))
870872
),
871873
factory.createMenuItem(StandardActions.ABOUT, new AboutAction())
872874
);

src/main/java/org/jabref/gui/SaveOrderConfigDisplay.fxml

Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -24,37 +24,38 @@
2424
<RadioButton fx:id="exportInSpecifiedOrder"
2525
text="%Export entries ordered as specified" toggleGroup="$saveOrderToggleGroup"/>
2626

27-
<GridPane alignment="CENTER_LEFT" hgap="10.0">
27+
<GridPane hgap="10.0" vgap="4.0">
2828
<columnConstraints>
29-
<ColumnConstraints hgrow="SOMETIMES" minWidth="-Infinity" prefWidth="100.0"/>
30-
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0"/>
31-
<ColumnConstraints hgrow="SOMETIMES" minWidth="10.0" prefWidth="100.0"/>
29+
<ColumnConstraints hgrow="NEVER" minWidth="25.0" maxWidth="25.0"/>
30+
<ColumnConstraints hgrow="SOMETIMES" percentWidth="30.0" />
31+
<ColumnConstraints hgrow="SOMETIMES" />
32+
<ColumnConstraints hgrow="SOMETIMES" halignment="LEFT"/>
3233
</columnConstraints>
3334
<rowConstraints>
34-
<RowConstraints prefHeight="30.0"/>
35-
<RowConstraints prefHeight="30.0"/>
36-
<RowConstraints prefHeight="30.0"/>
37-
<RowConstraints prefHeight="30.0"/>
38-
<RowConstraints prefHeight="30.0"/>
39-
<RowConstraints prefHeight="30.0"/>
35+
<RowConstraints minHeight="30.0" vgrow="SOMETIMES" />
36+
<RowConstraints minHeight="30.0" vgrow="SOMETIMES" />
37+
<RowConstraints minHeight="30.0" vgrow="SOMETIMES" />
4038
</rowConstraints>
4139

42-
<Label disable="${!exportInSpecifiedOrder.selected}" text="%Primary sort criterion" GridPane.rowIndex="0"/>
43-
<Label disable="${!exportInSpecifiedOrder.selected}" text="%Secondary sort criterion" GridPane.rowIndex="1"/>
44-
<Label disable="${!exportInSpecifiedOrder.selected}" text="%Tertiary sort criterion" GridPane.rowIndex="2"/>
40+
<Label text="%Primary sort criterion" GridPane.columnIndex="1" GridPane.rowIndex="0"
41+
disable="${!exportInSpecifiedOrder.selected}"/>
42+
<Label text="%Secondary sort criterion" GridPane.columnIndex="1" GridPane.rowIndex="1"
43+
disable="${!exportInSpecifiedOrder.selected}"/>
44+
<Label text="%Tertiary sort criterion" GridPane.columnIndex="1" GridPane.rowIndex="2"
45+
disable="${!exportInSpecifiedOrder.selected}"/>
4546

46-
<ComboBox fx:id="savePriSort" editable="true" GridPane.columnIndex="1" GridPane.rowIndex="0"
47+
<ComboBox fx:id="savePriSort" editable="true" GridPane.columnIndex="2" GridPane.rowIndex="0"
4748
disable="${!exportInSpecifiedOrder.selected}"/>
48-
<ComboBox fx:id="saveSecSort" editable="true" GridPane.columnIndex="1" GridPane.rowIndex="1"
49+
<ComboBox fx:id="saveSecSort" editable="true" GridPane.columnIndex="2" GridPane.rowIndex="1"
4950
disable="${!exportInSpecifiedOrder.selected}"/>
50-
<ComboBox fx:id="saveTerSort" editable="true" GridPane.columnIndex="1" GridPane.rowIndex="2"
51+
<ComboBox fx:id="saveTerSort" editable="true" GridPane.columnIndex="2" GridPane.rowIndex="2"
5152
disable="${!exportInSpecifiedOrder.selected}"/>
5253

5354
<CheckBox fx:id="savePriDesc" disable="${!exportInSpecifiedOrder.selected}" mnemonicParsing="false"
54-
text="%Descending" GridPane.columnIndex="2" GridPane.rowIndex="0"/>
55+
text="%Descending" GridPane.columnIndex="3" GridPane.rowIndex="0"/>
5556
<CheckBox fx:id="saveSecDesc" disable="${!exportInSpecifiedOrder.selected}" mnemonicParsing="false"
56-
text="%Descending" GridPane.columnIndex="2" GridPane.rowIndex="1"/>
57+
text="%Descending" GridPane.columnIndex="3" GridPane.rowIndex="1"/>
5758
<CheckBox fx:id="saveTerDesc" disable="${!exportInSpecifiedOrder.selected}" mnemonicParsing="false"
58-
text="%Descending" GridPane.columnIndex="2" GridPane.rowIndex="2"/>
59+
text="%Descending" GridPane.columnIndex="3" GridPane.rowIndex="2"/>
5960
</GridPane>
6061
</fx:root>

src/main/java/org/jabref/gui/actions/StandardActions.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,9 @@ public enum StandardActions implements Action {
8585
TOOGLE_OO(Localization.lang("OpenOffice/LibreOffice"), IconTheme.JabRefIcons.FILE_OPENOFFICE, KeyBinding.OPEN_OPEN_OFFICE_LIBRE_OFFICE_CONNECTION),
8686
TOGGLE_WEB_SEARCH(Localization.lang("Web search"), Localization.lang("Toggle web search interface"), IconTheme.JabRefIcons.WWW, KeyBinding.WEB_SEARCH),
8787

88-
PARSE_TEX(Localization.lang("Search for Citations in LaTeX Files"), IconTheme.JabRefIcons.LATEX_CITATIONS),
88+
PARSE_TEX(Localization.lang("Search for citations in LaTeX files..."), IconTheme.JabRefIcons.LATEX_CITATIONS),
8989
NEW_SUB_LIBRARY_FROM_AUX(Localization.lang("New sublibrary based on AUX file") + "...", Localization.lang("New BibTeX sublibrary") + Localization.lang("This feature generates a new library based on which entries are needed in an existing LaTeX document."), IconTheme.JabRefIcons.NEW),
90-
WRITE_XMP(Localization.lang("Write XMP-metadata to PDFs"), Localization.lang("Will write XMP-metadata to the PDFs linked from selected entries."), KeyBinding.WRITE_XMP),
90+
WRITE_XMP(Localization.lang("Write XMP metadata to PDFs"), Localization.lang("Will write XMP metadata to the PDFs linked from selected entries."), KeyBinding.WRITE_XMP),
9191
OPEN_FOLDER(Localization.lang("Open folder"), Localization.lang("Open folder"), KeyBinding.OPEN_FOLDER),
9292
OPEN_FILE(Localization.lang("Open file"), Localization.lang("Open file"), IconTheme.JabRefIcons.FILE, KeyBinding.OPEN_FILE),
9393
OPEN_CONSOLE(Localization.lang("Open terminal here"), Localization.lang("Open terminal here"), IconTheme.JabRefIcons.CONSOLE, KeyBinding.OPEN_CONSOLE),
@@ -145,13 +145,13 @@ public enum StandardActions implements Action {
145145
HELP_NAME_FORMATTER(Localization.lang("Help on Name Formatting"), IconTheme.JabRefIcons.HELP, KeyBinding.HELP),
146146
HELP_SPECIAL_FIELDS(Localization.lang("Help on special fields"), IconTheme.JabRefIcons.HELP, KeyBinding.HELP),
147147
WEB_MENU(Localization.lang("JabRef resources")),
148-
OPEN_WEBPAGE(Localization.lang("Website"), Localization.lang("Opens JabRef's website")),
148+
OPEN_WEBPAGE(Localization.lang("Website"), Localization.lang("Opens JabRef's website"), IconTheme.JabRefIcons.HOME),
149149
OPEN_FACEBOOK("Facebook", Localization.lang("Opens JabRef's Facebook page"), IconTheme.JabRefIcons.FACEBOOK),
150150
OPEN_TWITTER("Twitter", Localization.lang("Opens JabRef's Twitter page"), IconTheme.JabRefIcons.TWITTER),
151151
OPEN_BLOG(Localization.lang("Blog"), Localization.lang("Opens JabRef's blog"), IconTheme.JabRefIcons.BLOG),
152152
OPEN_DEV_VERSION_LINK(Localization.lang("Development version"), Localization.lang("Opens a link where the current development version can be downloaded")),
153153
OPEN_CHANGELOG(Localization.lang("View change log"), Localization.lang("See what has been changed in the JabRef versions")),
154-
FORK_ME(Localization.lang("Fork me on GitHub"), Localization.lang("Opens JabRef's GitHub page"), IconTheme.JabRefIcons.GITHUB),
154+
OPEN_GITHUB("GitHub", Localization.lang("Opens JabRef's GitHub page"), IconTheme.JabRefIcons.GITHUB),
155155
DONATE(Localization.lang("Donate to JabRef"), Localization.lang("Donate to JabRef"), IconTheme.JabRefIcons.DONATE),
156156
OPEN_FORUM(Localization.lang("Online help forum"), Localization.lang("Online help forum"), IconTheme.JabRefIcons.FORUM),
157157
ERROR_CONSOLE(Localization.lang("View event log"), Localization.lang("Display all error messages")),

0 commit comments

Comments
 (0)