diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 9964ff946dfe..2a1a625d7bc6 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -9,5 +9,4 @@ - [ ] Tests created for changes - [ ] Manually tested changed features in running JabRef - [ ] Screenshots added in PR description (for bigger UI changes) -- [ ] Ensured that [the git commit message is a good one](https://github.com/joelparkerhenderson/git_commit_message) -- [ ] Check documentation status (Issue created for outdated help page at [help.jabref.org](https://github.com/JabRef/help.jabref.org/issues)?) +- [ ] [Checked documentation](https://docs.jabref.org/): Is the information available and up to date? If not: Issue created at . diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index 06ceda21c2cc..5e62339204c5 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -11,17 +11,17 @@ jobs: include: - os: ubuntu-latest displayName: linux - jpackageDownload: https://download.java.net/java/early_access/jpackage/1/openjdk-14-jpackage+1-67_linux-x64_bin.tar.gz + jpackageDownload: https://download.java.net/java/early_access/jpackage/1/openjdk-14-jpackage+1-70_linux-x64_bin.tar.gz jdk14Path: /jdk-14 archivePortable: tar -czf build/distribution/JabRef-portable_linux.tar.gz -C build/distribution JabRef && rm -R build/distribution/JabRef - os: windows-latest displayName: windows - jpackageDownload: https://download.java.net/java/early_access/jpackage/1/openjdk-14-jpackage+1-67_windows-x64_bin.zip + jpackageDownload: https://download.java.net/java/early_access/jpackage/1/openjdk-14-jpackage+1-70_windows-x64_bin.zip jdk14Path: /jdk-14 archivePortable: 7z a -r build/distribution/JabRef-portable_windows.zip ./build/distribution/JabRef && rm -R build/distribution/JabRef - os: macOS-latest displayName: macOS - jpackageDownload: https://download.java.net/java/early_access/jpackage/1/openjdk-14-jpackage+1-67_osx-x64_bin.tar.gz + jpackageDownload: https://download.java.net/java/early_access/jpackage/1/openjdk-14-jpackage+1-70_osx-x64_bin.tar.gz jdk14Path: /jdk-14.jdk/Contents/Home archivePortable: tar -czf build/distribution/JabRef-portable_macos.tar.gz -C build/distribution JabRef.app && rm -R build/distribution/JabRef.app diff --git a/.travis.yml b/.travis.yml index 22c531f9877d..b9d4177fe1e6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -30,6 +30,7 @@ env: matrix: fast_finish: true allow_failures: + - env: TEST_SUITE=codecov - env: TEST_SUITE=fetcherTest - env: TEST_SUITE=databaseTest - env: TEST_SUITE=guiTest diff --git a/CHANGELOG.md b/CHANGELOG.md index 17873d43bf5c..5246bd3355fa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,6 +20,8 @@ We refer to [GitHub issues](https://github.com/JabRef/jabref/issues) by using `# - The entry editor is now open by default when JabRef starts up. [#5460](https://github.com/JabRef/jabref/issues/5460) - We added a new ADS fetcher to use the new ADS API [#4949](https://github.com/JabRef/jabref/issues/4949) - We added support of the [X11 primary selection](https://unix.stackexchange.com/a/139193/18033) [#2389](https://github.com/JabRef/jabref/issues/2389) +- We added support to switch between biblatex and bibtex library types. [#5550](https://github.com/JabRef/jabref/issues/5550) +- We changed the save action buttons to be easier to understand. [#5565](https://github.com/JabRef/jabref/issues/5565) - We made the columns for groups, files and uri in the main table reorderable and merged the clickable icon columns for uri, url, doi and eprint. [#5544](https://github.com/JabRef/jabref/pull/5544) ### Fixed @@ -28,12 +30,12 @@ We refer to [GitHub issues](https://github.com/JabRef/jabref/issues) by using `# - We fixed an issue where it was no longer possible to connect to LibreOffice. [#5261](https://github.com/JabRef/jabref/issues/5261) - The "All entries group" is no longer shown when no library is open. - We fixed an exception which occurred when closing JabRef. [#5348](https://github.com/JabRef/jabref/issues/5348) -- We fixed an issue where JabRef reports incorrectly about customized entry types. [#5332](https://github.com/JabRef/jabref/issues/5332) +- We fixed an issue where JabRef reports incorrectly about customized entry types. [#5332](https://github.com/JabRef/jabref/issues/5332) - We fixed a few problems that prevented JabFox to communicate with JabRef. [#4737](https://github.com/JabRef/jabref/issues/4737) [#4303](https://github.com/JabRef/jabref/issues/4303) -- We fixed an error where the groups containing an entry loose their highlight color when scrolling. [#5022](https://github.com/JabRef/jabref/issues/5022) +- We fixed an error where the groups containing an entry loose their highlight color when scrolling. [#5022](https://github.com/JabRef/jabref/issues/5022) - We fixed an error where scrollbars were not shown. [#5374](https://github.com/JabRef/jabref/issues/5374) - We fixed an error where an exception was thrown when merging entries. [#5169](https://github.com/JabRef/jabref/issues/5169) -- We fixed an error where certain metadata items were not serialized alphabetically. +- We fixed an error where certain metadata items were not serialized alphabetically. - After assigning an entry to a group, the item count is now properly colored to reflect the new membership of the entry. [#3112](https://github.com/JabRef/jabref/issues/3112) - The group panel is now properly updated when switching between libraries (or when closing/opening one). [#3142](https://github.com/JabRef/jabref/issues/3142) - We fixed an error where the number of matched entries shown in the group pane was not updated correctly. [#4441](https://github.com/JabRef/jabref/issues/4441) @@ -44,7 +46,7 @@ We refer to [GitHub issues](https://github.com/JabRef/jabref/issues) by using `# - We fixed an issue where multiple entries were highlighted in the web search result after scrolling. [#5035](https://github.com/JabRef/jabref/issues/5035) - We fixed an issue where the hover indication in the web search pane was not working. [#5277](https://github.com/JabRef/jabref/issues/5277) - We fixed an error mentioning "javafx.controls/com.sun.javafx.scene.control" that was thrown when interacting with the toolbar. -- We fixed an error where a cleared search was restored after switching libraries. [#4846](https://github.com/JabRef/jabref/issues/4846) +- We fixed an error where a cleared search was restored after switching libraries. [#4846](https://github.com/JabRef/jabref/issues/4846) - We fixed an exception which occurred when trying to open a non-existing file from the "Recent files"-menu [#5334](https://github.com/JabRef/jabref/issues/5334) - We fixed an issues where the search highlight in the entry preview did not worked. [#5069](https://github.com/JabRef/jabref/issues/5069) - The context menu for fields in the entry editor is back. [#5254](https://github.com/JabRef/jabref/issues/5254) @@ -53,7 +55,7 @@ We refer to [GitHub issues](https://github.com/JabRef/jabref/issues) by using `# - We re-introduced the feature to switch between different preview styles. [#5221](https://github.com/JabRef/jabref/issues/5221) - We fixed various issues (including [#5263](https://github.com/JabRef/jabref/issues/5263)) related to copying entries to the clipboard - We fixed some display errors in the preferences dialog and replaced some of the controls [#5033](https://github.com/JabRef/jabref/pull/5033) [#5047](https://github.com/JabRef/jabref/pull/5047) [#5062](https://github.com/JabRef/jabref/pull/5062) [#5141](https://github.com/JabRef/jabref/pull/5141) [#5185](https://github.com/JabRef/jabref/pull/5185) [#5265](https://github.com/JabRef/jabref/pull/5265) [#5315](https://github.com/JabRef/jabref/pull/5315) [#5360](https://github.com/JabRef/jabref/pull/5360) -- We fixed an exception which occurred when trying to import entries without an open library. [#5447](https://github.com/JabRef/jabref/issues/5447) +- We fixed an exception which occurred when trying to import entries without an open library. [#5447](https://github.com/JabRef/jabref/issues/5447) - After successful import of one or multiple bib entries the main table scrolls to the first imported entry [#5383](https://github.com/JabRef/jabref/issues/5383) - We fixed an exception which occurred when an invalid jstyle was loaded. [#5452](https://github.com/JabRef/jabref/issues/5452) - We fixed an error where the preview theme did not adapt to the "Dark" mode [#5463](https://github.com/JabRef/jabref/issues/5463) @@ -143,7 +145,7 @@ We refer to [GitHub issues](https://github.com/JabRef/jabref/issues) by using `# - Change default icon for groups to a circle because a colored version of the old icon was hard to distinguish from its black counterpart. - In the main table, the context menu appears now when you press the "context menu" button on the keyboard. [feature request in the forum](http://discourse.jabref.org/t/how-to-enable-keyboard-context-key-windows) - We added icons to the group side panel to quickly switch between `union` and `intersection` group view mode https://github.com/JabRef/jabref/issues/3269. -- We use `https` for [fetching from most online bibliographic database](https://help.jabref.org/en/#-using-online-bibliographic-database). +- We use `https` for [fetching from most online bibliographic database](https://docs.jabref.org/import-using-online-bibliographic-database). - We changed the default keyboard shortcuts for moving between entries when the entry editor is active to ̀alt + up/down. - Opening a new file now prompts the directory of the currently selected file, instead of the directory of the last opened file. - Window state is saved on close and restored on start. @@ -162,7 +164,7 @@ We refer to [GitHub issues](https://github.com/JabRef/jabref/issues) by using `# - We optimized the code responsible for connecting to an external database, which should lead to huge improvements in performance. - For automatically created groups, added ability to filter groups by entry type. [#4539](https://github.com/JabRef/jabref/issues/4539) - We added the ability to add field names from the Preferences Dialog [#4546](https://github.com/JabRef/jabref/issues/4546) -- We added the ability to change the column widths directly in the main +- We added the ability to change the column widths directly in the main . [#4546](https://github.com/JabRef/jabref/issues/4546) - We added a description of how recommendations were chosen and better error handling to Related Articles tab - We added the ability to execute default action in dialog by using with Ctrl + Enter combination [#4496](https://github.com/JabRef/jabref/issues/4496) diff --git a/README.md b/README.md index 599de1952761..fb15af17b061 100644 --- a/README.md +++ b/README.md @@ -64,9 +64,9 @@ The [latest stable release is available at FossHub](https://www.fosshub.com/JabR JabRef runs on any system equipped with the Java Virtual Machine (Java 11 or higher), which can be downloaded at no cost from [AdoptOpenDJK](https://adoptopenjdk.net/). From JabRef 4.0 onwards, [JavaFX] support has to be installed. - - Windows: JabRef offers an installer, which also adds a shortcut to JabRef to your start menu. Please also see our [Windows FAQ](https://help.jabref.org/en/FAQwindows) - - Linux: Please see our [Installation Guide](http://help.jabref.org/en/Installation). - - Mac OS X: Please see our [Mac OS X FAQ](https://help.jabref.org/en/FAQosx). + - Windows: JabRef offers an installer, which also adds a shortcut to JabRef to your start menu. Please also see our [Windows FAQ](https://docs.jabref.org/faq/faqwindows) + - Linux: Please see our [Installation Guide](https://docs.jabref.org/general/installation). + - Mac OS X: Please see our [Mac OS X FAQ](https://docs.jabref.org/faq/faqosx). In addition, JabRef can be downloaded as an executable `.jar` file. Try to double click the `jar` file or execute the following command: @@ -78,7 +78,7 @@ Try to double click the `jar` file or execute the following command: We are thankful for any bug reports or other feedback. If you have ideas for new features you want to be included in JabRef, [tell us in our forum](http://discourse.jabref.org/c/features)! -If you need support in using JabRef, please read [the documentation](https://help.jabref.org/) first and have a look at our [community forum](http://discourse.jabref.org/c/help). +If you need support in using JabRef, please read [the documentation](https://docs.jabref.org/) first and have a look at our [community forum](https://discourse.jabref.org/c/help). You can use our [GitHub issue tracker](https://github.com/JabRef/jabref/issues) to file bug reports. An explanation of donation possibilities and usage of donations is available at our [donations page](https://donations.jabref.org). diff --git a/build.gradle b/build.gradle index 31ab111735e6..a029c5a4a096 100644 --- a/build.gradle +++ b/build.gradle @@ -23,7 +23,7 @@ plugins { id 'com.github.ben-manes.versions' version '0.27.0' id 'org.javamodularity.moduleplugin' version '1.5.0' id 'org.openjfx.javafxplugin' version '0.0.8' - id 'org.beryx.jlink' version '2.16.3' + id 'org.beryx.jlink' version '2.16.4' } gradle.startParameter.showStacktrace = org.gradle.api.logging.configuration.ShowStacktrace.ALWAYS @@ -449,7 +449,8 @@ test { testLogging { // set options for log level LIFECYCLE - events = ["FAILED", "STANDARD_OUT", "STANDARD_ERROR"] + // for debugging tests: add "STANDARD_OUT", "STANDARD_ERROR" + events = ["FAILED"] exceptionFormat "full" } } diff --git a/buildres/linux/jabref.spec b/buildres/linux/jabref.spec new file mode 100644 index 000000000000..71c9574c4499 --- /dev/null +++ b/buildres/linux/jabref.spec @@ -0,0 +1,71 @@ +Summary: APPLICATION_SUMMARY +Name: APPLICATION_PACKAGE +Version: APPLICATION_VERSION +Release: APPLICATION_RELEASE +License: APPLICATION_LICENSE_TYPE +Vendor: APPLICATION_VENDOR +Prefix: %{dirname:APPLICATION_DIRECTORY} +Provides: APPLICATION_PACKAGE +%if "xAPPLICATION_GROUP" != x +Group: APPLICATION_GROUP +%endif + +Autoprov: 0 +Autoreq: 0 +%if "xPACKAGE_DEFAULT_DEPENDENCIES" != x || "xPACKAGE_CUSTOM_DEPENDENCIES" != x +Requires: PACKAGE_DEFAULT_DEPENDENCIES PACKAGE_CUSTOM_DEPENDENCIES +%endif + +#avoid ARCH subfolder +%define _rpmfilename %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm + +#comment line below to enable effective jar compression +#it could easily get your package size from 40 to 15Mb but +#build time will substantially increase and it may require unpack200/system java to install +%define __jar_repack %{nil} + +%description +APPLICATION_DESCRIPTION + +%prep + +%build + +%install +rm -rf %{buildroot} +install -d -m 755 %{buildroot}APPLICATION_DIRECTORY +cp -r %{_sourcedir}APPLICATION_DIRECTORY/* %{buildroot}APPLICATION_DIRECTORY +%if "xAPPLICATION_LICENSE_FILE" != x + %define license_install_file %{_defaultlicensedir}/%{name}-%{version}/%{basename:APPLICATION_LICENSE_FILE} + install -d -m 755 %{buildroot}%{dirname:%{license_install_file}} + install -m 644 APPLICATION_LICENSE_FILE %{buildroot}%{license_install_file} +%endif + +%files +%if "xAPPLICATION_LICENSE_FILE" != x + %license %{license_install_file} + %{dirname:%{license_install_file}} +%endif +# If installation directory for the application is /a/b/c, we want only root +# component of the path (/a) in the spec file to make sure all subdirectories +# are owned by the package. +%(echo APPLICATION_DIRECTORY | sed -e "s|\(^/[^/]\{1,\}\).*$|\1|") + +%post +install -D -m0755 /opt/jabref/lib/native-messaging-host/firefox/org.jabref.jabref.json /usr/lib/mozilla/native-messaging-hosts/org.jabref.jabref.json +install -D -m0755 /opt/jabref/lib/native-messaging-host/chromium/org.jabref.jabref.json /etc/chromium/native-messaging-hosts/org.jabref.jabref.json +install -D -m0755 /opt/jabref/lib/native-messaging-host/chromium/org.jabref.jabref.json /etc/opt/chrome/native-messaging-hosts/org.jabref.jabref.json +DESKTOP_COMMANDS_INSTALL + +%preun +for NATIVE_MESSAGING_JSON in "/usr/lib/mozilla/native-messaging-hosts/org.jabref.jabref.json"\ + "/etc/chromium/native-messaging-hosts/org.jabref.jabref.json"\ + "/etc/opt/chrome/native-messaging-hosts/org.jabref.jabref.json"; do + if [ -e $NATIVE_MESSAGING_JSON ] && grep --quiet '"path": "/opt' $NATIVE_MESSAGING_JSON; then + rm $NATIVE_MESSAGING_JSON + fi +done +UTILITY_SCRIPTS +DESKTOP_COMMANDS_UNINSTALL + +%clean \ No newline at end of file diff --git a/buildres/linux/native-messaging-host/chromium/org.jabref.jabref.json b/buildres/linux/native-messaging-host/chromium/org.jabref.jabref.json new file mode 100644 index 000000000000..6283016eafef --- /dev/null +++ b/buildres/linux/native-messaging-host/chromium/org.jabref.jabref.json @@ -0,0 +1,9 @@ +{ + "name": "org.jabref.jabref", + "description": "JabRef", + "path": "/opt/jabref/lib/jabrefHost.py", + "type": "stdio", + "allowed_origins": [ + "chrome-extension://bifehkofibaamoeaopjglfkddgkijdlh/" + ] +} diff --git a/buildres/linux/org.jabref.jabref.json b/buildres/linux/native-messaging-host/firefox/org.jabref.jabref.json similarity index 75% rename from buildres/linux/org.jabref.jabref.json rename to buildres/linux/native-messaging-host/firefox/org.jabref.jabref.json index 8516f3882661..1edebc9c576f 100644 --- a/buildres/linux/org.jabref.jabref.json +++ b/buildres/linux/native-messaging-host/firefox/org.jabref.jabref.json @@ -4,6 +4,7 @@ "path": "/opt/jabref/lib/jabrefHost.py", "type": "stdio", "allowed_extensions": [ - "browserextension@jabref.org" + "browserextension@jabref.org", + "@jabfox" ] } diff --git a/buildres/linux/postinst b/buildres/linux/postinst index ea5525ebd03e..1c3af73aa249 100644 --- a/buildres/linux/postinst +++ b/buildres/linux/postinst @@ -19,8 +19,9 @@ set -e case "$1" in configure) - INSTALL_PATH="/usr/lib/mozilla/native-messaging-hosts" - install -D -m0755 /opt/jabref/lib/org.jabref.jabref.json $INSTALL_PATH/org.jabref.jabref.json + install -D -m0755 /opt/jabref/lib/native-messaging-host/firefox/org.jabref.jabref.json /usr/lib/mozilla/native-messaging-hosts/org.jabref.jabref.json + install -D -m0755 /opt/jabref/lib/native-messaging-host/chromium/org.jabref.jabref.json /etc/chromium/native-messaging-hosts/org.jabref.jabref.json + install -D -m0755 /opt/jabref/lib/native-messaging-host/chromium/org.jabref.jabref.json /etc/opt/chrome/native-messaging-hosts/org.jabref.jabref.json DESKTOP_COMMANDS_INSTALL ;; diff --git a/buildres/linux/postrm b/buildres/linux/postrm index 2cd3bfb9079c..5d9530a3bbd9 100644 --- a/buildres/linux/postrm +++ b/buildres/linux/postrm @@ -16,12 +16,16 @@ set -e # # for details, see http://www.debian.org/doc/debian-policy/ or # the debian-policy package + case "$1" in purge|remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) - NATIVE_MESSAGING_JSON="/usr/lib/mozilla/native-messaging-hosts/org.jabref.jabref.json" - if [ -e $NATIVE_MESSAGING_JSON ] && grep --quiet '"path": "/opt' $NATIVE_MESSAGING_JSON; then - rm $NATIVE_MESSAGING_JSON - fi + for NATIVE_MESSAGING_JSON in "/usr/lib/mozilla/native-messaging-hosts/org.jabref.jabref.json"\ + "/etc/chromium/native-messaging-hosts/org.jabref.jabref.json"\ + "/etc/opt/chrome/native-messaging-hosts/org.jabref.jabref.json"; do + if [ -e $NATIVE_MESSAGING_JSON ] && grep --quiet '"path": "/opt' $NATIVE_MESSAGING_JSON; then + echo $NATIVE_MESSAGING_JSON + fi + done ;; *) @@ -30,4 +34,4 @@ case "$1" in ;; esac -exit 0 \ No newline at end of file +exit 0 diff --git a/buildres/windows/JabRef-post-image.wsf b/buildres/windows/JabRef-post-image.wsf index b7feaf3c66d2..285fd471972b 100644 --- a/buildres/windows/JabRef-post-image.wsf +++ b/buildres/windows/JabRef-post-image.wsf @@ -16,8 +16,8 @@ var contents = wxsFile.ReadAll(); wxsFile.Close(); - // Add registry values for JabFox - contents = contents.replace("", ""); + // Add registry values for JabRef Browser Extension + contents = contents.replace("", ""); // Specify correct icon in Add/Remove Programs contents = contents.replace("", ""); diff --git a/buildres/windows/jabref.json b/buildres/windows/jabref.json index d636c8b71a08..30dfc79034a3 100644 --- a/buildres/windows/jabref.json +++ b/buildres/windows/jabref.json @@ -4,6 +4,7 @@ "path": "JabRefHost.bat", "type": "stdio", "allowed_extensions": [ - "browserextension@jabref.org" + "browserextension@jabref.org", + "@jabfox" ] } diff --git a/docs/adr/0001-use-crowdin-for-translations.md b/docs/adr/0001-use-crowdin-for-translations.md index 0d8955782abb..5b53d44fad65 100644 --- a/docs/adr/0001-use-crowdin-for-translations.md +++ b/docs/adr/0001-use-crowdin-for-translations.md @@ -9,7 +9,7 @@ The JabRef UI is offered in multiple languages. It should be easy for translator * Use [Crowdin](http://crowdin.com/) * Use [popeye](https://github.com/JabRef/popeye) * Use [Lingohub](https://lingohub.com/) -* Keep current GitHub flow. See the [Step-by-step guide](https://github.com/JabRef/help.jabref.org/blob/d5569bebdb0e1de5c71401bbfba45311c19c80a8/en/TranslatingGUI.md#step-by-step-guide). +* Keep current GitHub flow. See the [Step-by-step guide](https://docs.jabref.org/faq/how-to-translate-the-ui). ## Decision Outcome diff --git a/docs/adr/0004-use-mariadb-connector.md b/docs/adr/0004-use-mariadb-connector.md index 413364bfe356..b7d361f7e6cb 100644 --- a/docs/adr/0004-use-mariadb-connector.md +++ b/docs/adr/0004-use-mariadb-connector.md @@ -3,7 +3,7 @@ ## Context and Problem Statement JabRef needs to connect to a MySQL database. -See [Shared SQL Database](https://help.jabref.org/en/SQLDatabase) for more information. +See [Shared SQL Database](https://docs.jabref.org/collaborative-work/sqldatabase) for more information. ## Considered Options diff --git a/docs/adr/0005-fully-support-utf8-only-for-latex-files.md b/docs/adr/0005-fully-support-utf8-only-for-latex-files.md index 6e066e8b7d89..337511fe0c49 100644 --- a/docs/adr/0005-fully-support-utf8-only-for-latex-files.md +++ b/docs/adr/0005-fully-support-utf8-only-for-latex-files.md @@ -2,7 +2,7 @@ ## Context and Problem Statement -The feature [search for citations](https://github.com/JabRef/help.jabref.org/issues/210) displays the content of LaTeX files. +The feature [search for citations](https://github.com/JabRef/user-documentation/issues/210) displays the content of LaTeX files. The LaTeX files are text files and might be encoded arbitrarily. ## Considered Options diff --git a/src/main/java/org/jabref/gui/JabRefFrame.java b/src/main/java/org/jabref/gui/JabRefFrame.java index 5e0d65f43c8e..74e5dcd599e5 100644 --- a/src/main/java/org/jabref/gui/JabRefFrame.java +++ b/src/main/java/org/jabref/gui/JabRefFrame.java @@ -729,6 +729,7 @@ private MenuBar createMenu() { //@formatter:off library.getItems().addAll( factory.createMenuItem(StandardActions.NEW_ENTRY, new NewEntryAction(this, dialogService, Globals.prefs, stateManager)), + factory.createMenuItem(StandardActions.NEW_ENTRY_FROM_PLAINTEX, new ExtractBibtexAction(stateManager)), factory.createMenuItem(StandardActions.DELETE_ENTRY, new OldDatabaseCommandWrapper(Actions.DELETE, this, stateManager)), new SeparatorMenuItem(), @@ -769,6 +770,7 @@ private MenuBar createMenu() { factory.createMenuItem(StandardActions.WRITE_XMP, new OldDatabaseCommandWrapper(Actions.WRITE_XMP, this, stateManager)), factory.createMenuItem(StandardActions.COPY_LINKED_FILES, new CopyFilesAction(stateManager, this.getDialogService())), factory.createMenuItem(StandardActions.EXTRACT_BIBTEX, new ExtractBibtexAction(stateManager)), + new SeparatorMenuItem(), lookupIdentifiers, diff --git a/src/main/java/org/jabref/gui/actions/StandardActions.java b/src/main/java/org/jabref/gui/actions/StandardActions.java index a47395df3064..1c78808a1663 100644 --- a/src/main/java/org/jabref/gui/actions/StandardActions.java +++ b/src/main/java/org/jabref/gui/actions/StandardActions.java @@ -138,7 +138,6 @@ public enum StandardActions implements Action { DOWNLOAD_FULL_TEXT(Localization.lang("Search full text documents online"), IconTheme.JabRefIcons.FILE_SEARCH, KeyBinding.DOWNLOAD_FULL_TEXT), CLEANUP_ENTRIES(Localization.lang("Cleanup entries"), IconTheme.JabRefIcons.CLEANUP_ENTRIES, KeyBinding.CLEANUP), SET_FILE_LINKS(Localization.lang("Automatically set file links"), KeyBinding.AUTOMATICALLY_LINK_FILES), - EXTRACT_BIBTEX(Localization.lang("Extract BibTeX from plain text")), HELP(Localization.lang("Online help"), IconTheme.JabRefIcons.HELP, KeyBinding.HELP), HELP_KEY_PATTERNS(Localization.lang("Help on key patterns"), IconTheme.JabRefIcons.HELP, KeyBinding.HELP), diff --git a/src/main/java/org/jabref/gui/cleanup/CleanupPresetPanel.java b/src/main/java/org/jabref/gui/cleanup/CleanupPresetPanel.java index 719c11bc2672..563fb7ac9e40 100644 --- a/src/main/java/org/jabref/gui/cleanup/CleanupPresetPanel.java +++ b/src/main/java/org/jabref/gui/cleanup/CleanupPresetPanel.java @@ -12,7 +12,6 @@ import javafx.scene.layout.VBox; import org.jabref.logic.cleanup.CleanupPreset; -import org.jabref.logic.cleanup.Cleanups; import org.jabref.logic.l10n.Localization; import org.jabref.model.database.BibDatabaseContext; import org.jabref.model.entry.field.StandardField; @@ -64,7 +63,7 @@ private void init(CleanupPreset cleanupPreset, FilePreferences filePreferences) cleanUpUpgradeExternalLinks.setText(Localization.lang("Upgrade external PDF/PS links to use the '%0' field.", StandardField.FILE.getDisplayName())); - cleanUpFormatters = new FieldFormatterCleanupsPanel(Localization.lang("Run field formatter:"), Cleanups.DEFAULT_SAVE_ACTIONS); + cleanUpFormatters = new FieldFormatterCleanupsPanel(Localization.lang("Run field formatter:")); formatterContainer.getChildren().setAll(cleanUpFormatters); String currentPattern = Localization.lang("Filename format pattern") diff --git a/src/main/java/org/jabref/gui/cleanup/FieldFormatterCleanupsPanel.java b/src/main/java/org/jabref/gui/cleanup/FieldFormatterCleanupsPanel.java index 23917990ebec..7ef6dfc4d566 100644 --- a/src/main/java/org/jabref/gui/cleanup/FieldFormatterCleanupsPanel.java +++ b/src/main/java/org/jabref/gui/cleanup/FieldFormatterCleanupsPanel.java @@ -42,7 +42,6 @@ public class FieldFormatterCleanupsPanel extends GridPane { private static final String DESCRIPTION = Localization.lang("Description") + ": "; private final CheckBox cleanupEnabled; - private final FieldFormatterCleanups defaultFormatters; private final List availableFormatters; private FieldFormatterCleanups fieldFormatterCleanups; private ListView actionsList; @@ -50,13 +49,12 @@ public class FieldFormatterCleanupsPanel extends GridPane { private ComboBox selectFieldCombobox; private Button addButton; private Label descriptionAreaText; - private Button removeButton; - private Button resetButton; + private Button removeSelectedButton; + private Button removeAllButton; private Button recommendButton; private ObservableList actions; - public FieldFormatterCleanupsPanel(String description, FieldFormatterCleanups defaultFormatters) { - this.defaultFormatters = Objects.requireNonNull(defaultFormatters); + public FieldFormatterCleanupsPanel(String description) { cleanupEnabled = new CheckBox(description); availableFormatters = Cleanups.getBuiltInFormatters(); availableFormatters.add(new ProtectTermsFormatter(Globals.protectedTermsLoader)); @@ -110,12 +108,12 @@ private void buildLayout() { .install(actionsList); add(actionsList, 1, 1, 3, 1); - resetButton = new Button(Localization.lang("Reset")); - resetButton.setOnAction(e -> actions.setAll(defaultFormatters.getConfiguredActions())); + removeAllButton = new Button(Localization.lang("Remove all")); + removeAllButton.setOnAction(e -> actions.clear()); BibDatabaseContext databaseContext = JabRefGUI.getMainFrame().getCurrentBasePanel().getBibDatabaseContext(); - recommendButton = new Button(Localization.lang("Recommended for %0", databaseContext.getMode().getFormattedName())); + recommendButton = new Button(Localization.lang("Reset to recommended")); boolean isBiblatex = databaseContext.isBiblatexMode(); recommendButton.setOnAction(e -> { @@ -126,14 +124,14 @@ private void buildLayout() { } }); - removeButton = new Button(Localization.lang("Remove selected")); - removeButton.setOnAction(e -> actions.remove(actionsList.getSelectionModel().getSelectedItem())); + removeSelectedButton = new Button(Localization.lang("Remove selected")); + removeSelectedButton.setOnAction(e -> actions.remove(actionsList.getSelectionModel().getSelectedItem())); descriptionAreaText = new Label(DESCRIPTION); descriptionAreaText.setWrapText(true); - add(removeButton, 3, 2, 1, 1); - add(resetButton, 1, 2, 1, 1); - add(recommendButton, 2, 2, 1, 1); + add(recommendButton, 1, 2, 1, 1); + add(removeSelectedButton, 2, 2, 1, 1); + add(removeAllButton, 3, 2, 1, 1); add(getSelectorPanel(), 1, 3, 3, 1); add(descriptionAreaText, 1, 4, 3, 1); @@ -234,8 +232,8 @@ private void setStatus(boolean status) { selectFieldCombobox.setDisable(!status); formattersCombobox.setDisable(!status); addButton.setDisable(!status); - removeButton.setDisable(!status); - resetButton.setDisable(!status); + removeSelectedButton.setDisable(!status); + removeAllButton.setDisable(!status); recommendButton.setDisable(!status); } diff --git a/src/main/java/org/jabref/gui/help/HelpAction.java b/src/main/java/org/jabref/gui/help/HelpAction.java index 603e055abaf0..1cfe14937ffa 100644 --- a/src/main/java/org/jabref/gui/help/HelpAction.java +++ b/src/main/java/org/jabref/gui/help/HelpAction.java @@ -1,15 +1,8 @@ package org.jabref.gui.help; -import java.util.HashSet; -import java.util.Set; -import java.util.stream.Collectors; -import java.util.stream.Stream; - -import org.jabref.Globals; import org.jabref.gui.actions.SimpleCommand; import org.jabref.gui.desktop.JabRefDesktop; import org.jabref.logic.help.HelpFile; -import org.jabref.preferences.JabRefPreferences; /** * This Action keeps a reference to a URL. When activated, it shows the help @@ -17,12 +10,6 @@ */ public class HelpAction extends SimpleCommand { - /** - * New languages of the help have to be added here - */ - private static final Set AVAILABLE_LANG_FILES = Stream.of("en", "de", "fr", "in", "ja") - .collect(Collectors.toCollection(HashSet::new)); - private HelpFile helpPage; public HelpAction(HelpFile helpPage) { @@ -30,15 +17,7 @@ public HelpAction(HelpFile helpPage) { } public static void openHelpPage(HelpFile helpPage) { - String lang = Globals.prefs.get(JabRefPreferences.LANGUAGE); - StringBuilder sb = new StringBuilder("https://help.jabref.org/"); - - if (AVAILABLE_LANG_FILES.contains(lang)) { - sb.append(lang); - sb.append("/"); - } else { - sb.append("en/"); - } + StringBuilder sb = new StringBuilder("https://docs.jabref.org/"); sb.append(helpPage.getPageName()); JabRefDesktop.openBrowserShowPopup(sb.toString()); } diff --git a/src/main/java/org/jabref/gui/libraryproperties/LibraryPropertiesDialog.fxml b/src/main/java/org/jabref/gui/libraryproperties/LibraryPropertiesDialog.fxml index 76aa87d595cd..12f7febeb966 100644 --- a/src/main/java/org/jabref/gui/libraryproperties/LibraryPropertiesDialog.fxml +++ b/src/main/java/org/jabref/gui/libraryproperties/LibraryPropertiesDialog.fxml @@ -1,17 +1,9 @@ - - - - - - - - - - - - + + + + @@ -22,7 +14,7 @@ - + @@ -32,8 +24,26 @@ -