Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix localization #11602

Merged
merged 1 commit into from
Aug 10, 2024
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
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public LatexCitationsTab(BibDatabaseContext databaseContext,
this.progressIndicator = new ProgressIndicator();
this.citationsDisplay = new CitationsDisplay();

setText(Localization.lang("LaTeX Citations"));
setText(Localization.lang("LaTeX citations"));
setTooltip(new Tooltip(Localization.lang("Search citations for this entry in LaTeX files")));
setGraphic(IconTheme.JabRefIcons.LATEX_CITATIONS.getGraphicNode());
setSearchPane();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,18 +25,18 @@
fx:id="autoLinkFilesEnabled"
text="%Automatically search and show unlinked files in the entry editor"/>

<CheckBox fx:id="enableRelatedArticlesTab" text="%Show 'Related Articles' tab"/>
<CheckBox fx:id="enableRelatedArticlesTab" text="%Show tab 'Related articles'"/>
<CheckBox fx:id="acceptRecommendations" text="%Accept recommendations from Mr. DLib"
disable="${!enableRelatedArticlesTab.selected}">
<padding>
<Insets left="20.0"/>
</padding>
</CheckBox>
<CheckBox fx:id="enableLatexCitationsTab" text="%Show 'LaTeX Citations' tab"/>
<CheckBox fx:id="enableLatexCitationsTab" text="%Show tab 'LaTeX citations'"/>
<CheckBox fx:id="enableValidation" text="%Show validation messages"/>
<CheckBox fx:id="allowIntegerEdition" text="%Allow integers in 'edition' field in BibTeX mode"/>
<CheckBox fx:id="journalPopupEnabled" text="%Fetch journal information online to show"/>
<CheckBox fx:id="enableSciteTab" text="%Show 'Citation information' tab"/>
<CheckBox fx:id="enableSciteTab" text="%Show tab 'Citation information'"/>
<CheckBox fx:id="showUserCommentsField" text="%Show user comments field"/>

<Label styleClass="sectionHeader" text="%Custom editor tabs"/>
Expand Down
8 changes: 3 additions & 5 deletions src/main/java/org/jabref/gui/util/FileNodeViewModel.java
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,7 @@ public static String formatDateTime(FileTime fileTime) {
*/
public String getDisplayText() {
if (path.toFile().isDirectory()) {
return "%s (%s %s)".formatted(path.getFileName(), fileCount,
fileCount == 1 ? Localization.lang("file") : Localization.lang("files"));
return "%s (%s %s)".formatted(path.getFileName(), Localization.lang("%0 file(s)", fileCount));
}
return path.getFileName().toString();
}
Expand All @@ -76,14 +75,13 @@ public String getDisplayText() {
*/
public String getDisplayTextWithEditDate() {
if (path.toFile().isDirectory()) {
return "%s (%s %s)".formatted(path.getFileName(), fileCount,
fileCount == 1 ? Localization.lang("file") : Localization.lang("files"));
return "%s (%s %s)".formatted(path.getFileName(), Localization.lang("%0 file(s)", fileCount));
}
FileTime lastEditedTime = null;
try {
lastEditedTime = Files.getLastModifiedTime(path);
} catch (IOException e) {
LOGGER.error("Exception Caught", e);
LOGGER.error("Could not get last modified time", e);
}
return "%s (%s: %s)".formatted(path.getFileName().toString(), Localization.lang("last edited"), formatDateTime(lastEditedTime));
}
Expand Down
20 changes: 11 additions & 9 deletions src/main/resources/l10n/JabRef_en.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2055,29 +2055,31 @@ There\ already\ exists\ an\ external\ file\ type\ with\ the\ same\ extension=The
There\ already\ exists\ an\ external\ file\ type\ with\ the\ same\ name=There already exists an external file type with the same name


Search\ for\ citations\ in\ LaTeX\ files...=Search for citations in LaTeX files...
LaTeX\ Citations\ Search\ Results=LaTeX Citations Search Results
LaTeX\ files\ directory\:=LaTeX files directory:
LaTeX\ files\ found\:=LaTeX files found:
files=files
Show\ 'LaTeX\ Citations'\ tab=Show 'LaTeX Citations' tab
Show\ 'Citation\ information'\ tab=Show 'Citation information' tab
Show\ tab\ 'LaTeX\ citations'=Show tab 'LaTeX citations'
Show\ tab\ 'Citation\ information'=Show tab 'Citation information'
Search\ scite.ai\ for\ Smart\ Citations=Search scite.ai for Smart Citations
See\ full\ report\ at\ [%0]=See full report at [%0]
No\ active\ entry=No active entry
This\ entry\ does\ not\ have\ a\ DOI=This entry does not have a DOI
Tallies\ for\ %0=Tallies for %0

LaTeX\ Citations=LaTeX Citations
LaTeX\ citations=LaTeX citations
Search\ for\ citations\ in\ LaTeX\ files...=Search for citations in LaTeX files...
LaTeX\ Citations\ Search\ Results=LaTeX Citations Search Results
LaTeX\ files\ directory\:=LaTeX files directory:
LaTeX\ files\ found\:=LaTeX files found:
%0\ file(s)=%0 file(s)
Search\ citations\ for\ this\ entry\ in\ LaTeX\ files=Search citations for this entry in LaTeX files
No\ citations\ found=No citations found
No\ LaTeX\ files\ containing\ this\ entry\ were\ found.=No LaTeX files containing this entry were found.
Current\ search\ directory\ does\ not\ exist\:\ %0= Current search directory does not exist: %0
Selected\ entry\ does\ not\ have\ an\ associated\ citation\ key.=Selected entry does not have an associated citation key.
Current\ search\ directory\:=Current search directory:
Set\ LaTeX\ file\ directory=Set LaTeX file directory

Import\ entries\ from\ LaTeX\ files=Import entries from LaTeX files
Import\ new\ entries=Import new entries

Group\ color=Group color

Columns=Columns
Expand Down Expand Up @@ -2642,7 +2644,7 @@ Help\ on\ external\ applications=Help on external applications
Identifier-based\ Web\ Search=Identifier-based Web Search

Related\ articles=Related articles
Show\ 'Related\ Articles'\ tab=Show 'Related Articles' tab
Show\ tab\ 'Related\ articles'=Show tab 'Related articles'

Pushing\ citations\ to\ TeXShop\ is\ only\ possible\ on\ macOS\!=Pushing citations to TeXShop is only possible on macOS!

Expand Down
Loading