Skip to content

Switch to Ikonli#7424

Merged
Siedlerchr merged 23 commits into
masterfrom
ikonlimaterial
Feb 23, 2021
Merged

Switch to Ikonli#7424
Siedlerchr merged 23 commits into
masterfrom
ikonlimaterial

Conversation

@Siedlerchr

@Siedlerchr Siedlerchr commented Feb 6, 2021

Copy link
Copy Markdown
Member

Fixes #7058

grafik

Group with quadcopter icon
grafik

Remaining Issue:

  • Fix Lookup in GroupNodeViewModel
  • Fix GlyphSize setting
  • Change in CHANGELOG.md described (if applicable)
  • Tests created for changes (if applicable)
  • Manually tested changed features in running JabRef (always required)
  • Screenshots added in PR description (for UI changes)
  • Checked documentation: Is the information available and up to date? If not created an issue at https://github.com/JabRef/user-documentation/issues or, even better, submitted a pull request to the documentation repository.

Needs some more changes
@Siedlerchr Siedlerchr marked this pull request as draft February 6, 2021 16:55
Comment thread src/main/java/org/jabref/gui/icon/InternalMaterialDesignIcon.java
@Siedlerchr Siedlerchr marked this pull request as ready for review February 7, 2021 17:25
@Siedlerchr Siedlerchr changed the title [WIP] Switch to Ikonli Switch to Ikonli Feb 7, 2021
@Siedlerchr

Copy link
Copy Markdown
Member Author

Parsing of Group icons works also fine and we can now use all of MateralDesignIcons2

@Siedlerchr Siedlerchr added the status: ready-for-review Pull Requests that are ready to be reviewed by the maintainers label Feb 7, 2021
@calixtus

calixtus commented Feb 7, 2021

Copy link
Copy Markdown
Member

Besides the checkstyle issues, looks good to me.

remove fontawesomefx update checker rule from gradle
@Siedlerchr

Copy link
Copy Markdown
Member Author

Gui Test is still failing, need to check that

@tobiasdiez tobiasdiez left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That looks very nice! Thanks!

A few minor comments from my side

Comment thread src/main/java/org/jabref/gui/icon/IconTheme.java Outdated
private static InputStream getMaterialDesignIconsStream() {
return IconTheme.class.getResourceAsStream("/fonts/materialdesignicons-webfont.ttf");
public static Optional<JabRefIcon> findIcon(String code, Color color) {
return ICON_NAMES.stream().filter(icon -> icon.toString().equals(code.toUpperCase(Locale.ENGLISH)))

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe make ICON_NAMES a hashmap? Looking up the icon via the filter can otherwise become quite expensive.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And maybe initalize ICON_NAMES lazily, i.e. only when findIcon is called.

Comment thread src/main/java/org/jabref/gui/icon/IconTheme.java
public JabRefIconView(IconTheme.JabRefIcons icon) {
this(icon, "1em");

super(icon.getIkon());

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Refactor to this(icon, calculateDefaultSize()) ?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't work because I need getFont from the super class.

Comment thread src/main/java/org/jabref/gui/icon/JabRefIcon.java Outdated
* upstream/master:
  Bump unirest-java from 3.11.10 to 3.11.11 (#7428)
  Bump libreoffice from 7.0.4 to 7.1.0 (#7431)
  Bump unoloader from 7.0.4 to 7.1.0 (#7432)
  Bump byte-buddy-parent from 1.10.19 to 1.10.20 (#7434)
  Bump junit-platform-launcher from 1.7.0 to 1.7.1 (#7435)
  Bump junit-jupiter from 5.7.0 to 5.7.1 (#7436)
  Bump gittools/actions from v0.9.8 to v0.9.9 (#7433)
  Bump junit-vintage-engine from 5.7.0 to 5.7.1 (#7429)
  Bump lucene-queryparser from 8.7.0 to 8.8.0 (#7430)
@Siedlerchr

Copy link
Copy Markdown
Member Author

I have no clue why the GUI test fails, somehow it can't find the icon from our ikon provider

@Siedlerchr

Copy link
Copy Markdown
Member Author

The GUI Test works in general (test in Eclipse), but no clue how to modify the module-info.test to get it work.

@calixtus

Copy link
Copy Markdown
Member

Status: Tests failing because gradle is missing some testing plugins. module-info-test Ideas?
https://github.com/java9-modularity/gradle-modules-plugin#how-does-it-work

* upstream/master:
  Bump pascalgn/automerge-action from v0.13.0 to v0.13.1 (#7445)
  Auto-approve depend-a-bot-PRs (#7332)
  Clarify that changelog is user-facing
  Remove unmaintained AUTHORS file
  Fixes the issue "Non valid number as font size results in an uncaught exception." (#7438)
  Zbmath fetcher (#7440)
  Bump me.champeau.gradle.jmh from 0.5.2 to 0.5.3 (#7444)
  Bump styfle/cancel-workflow-action from 0.7.0 to 0.8.0 (#7446)
@Siedlerchr Siedlerchr merged commit e50566a into master Feb 23, 2021
@Siedlerchr Siedlerchr deleted the ikonlimaterial branch February 23, 2021 21:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status: ready-for-review Pull Requests that are ready to be reviewed by the maintainers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Switch from FontAwesomeFX to Ikonli

4 participants