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

Don't enforce default Windows font #3008

Merged
merged 2 commits into from
Jul 18, 2017
Merged

Don't enforce default Windows font #3008

merged 2 commits into from
Jul 18, 2017

Conversation

LinusDietz
Copy link
Member

@LinusDietz LinusDietz commented Jul 13, 2017

Check below #3008 (comment)

Default Arial has only 3988 glyphs (cf. https://en.wikipedia.org/wiki/Unicode_font#List_of_Unicode_fonts), where italics don't seem to be supported.

To fix the issue at hand I would propose to change the font to GNU Unifont](https://en.wikipedia.org/wiki/GNU_Unifont) which supports 63,449 glyphs.

License-wise there shouldn't be any issues:

The software on this site, unless otherwise noted, is released under the terms of the GNU General Public License (GNU GPL) version 2.0, or (at your option) a later version. The precompiled fonts are released under the terms of the GNU GPL version 2, or (at your option) a later version, with the exception that embedding the font in a document does not in itself bind that document to the terms of the GPL.
source: unifoundry.com

  • Screenshots added (for bigger UI changes)
  • Manually tested changed features in running JabRef

unifont

@LinusDietz LinusDietz requested a review from koppor July 13, 2017 15:56
@LinusDietz LinusDietz added build-system status: ready-for-review Pull Requests that are ready to be reviewed by the maintainers ui and removed build-system labels Jul 13, 2017
@lenhard
Copy link
Member

lenhard commented Jul 13, 2017

On my Win7 system, this font seems to be unavailable. I cannot select it in the preferences dialog and resetting the preferences does not help as well.

Maybe the real solution here is to tell the users they should install and configure a font that supports italics? Then, we would solve this issue by documentation?

@LinusDietz
Copy link
Member Author

LinusDietz commented Jul 13, 2017

I have removed the font default now. On my win10 system it defaults to "Dialog" and the italic texts are shown.
@lenhard, can you check again what happens on Windows 7?

@LinusDietz LinusDietz requested a review from lenhard July 13, 2017 16:50
@LinusDietz LinusDietz changed the title Use GNU Unifont as default Windows font Don't enforce default Windows font Jul 13, 2017
@lenhard
Copy link
Member

lenhard commented Jul 13, 2017

I get a font named "Dialog", but unfortunately no italics.

EDIT: And I have no clue why comment just appeared above those last two commits...

@LinusDietz
Copy link
Member Author

@lenhard because my windows system time is broken....

@LinusDietz
Copy link
Member Author

So what we need is any font that is available and works on all Windows versions :/

Copy link
Member

@tobiasdiez tobiasdiez left a comment

Choose a reason for hiding this comment

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

I think this is a good solution. Yes, maybe on some systems it does not work but at least partly it is a fix. I doubt that many users have \textit in the title. Thus, in my opinion, we can wait and hope that a migration to JavaFX solves the problem for everyone.

@AEgit
Copy link

AEgit commented Jul 13, 2017

I might add something on this.
I agree that not seeing the italics in the title is itself not a big issue (although it would be nice to have it at a certain point in time).
I disagree, however, with the assumption that not many users have \textit in their title. Genus and species names in biology have to (!) be written in italics. I guess therefore, that every user that is somewhat affiliated with biology will have articles that have italics in their titles.

@koppor
Copy link
Member

koppor commented Jul 14, 2017

Why removing the default font? Has "Dialog" more characters than Arial? OK, could be OK for me...

However, I checked stackoverflow: embedding a font in Java and also that.

@koppor koppor added status: waiting-for-feedback The submitter or other users need to provide more information about the issue and removed status: ready-for-review Pull Requests that are ready to be reviewed by the maintainers labels Jul 16, 2017
@koppor
Copy link
Member

koppor commented Jul 18, 2017

It seems that there is no font that we can embed perfectly.

@koppor koppor merged commit 7d31fa2 into master Jul 18, 2017
@koppor koppor deleted the fix-2784 branch July 18, 2017 13:09
@lenhard
Copy link
Member

lenhard commented Jul 20, 2017

@AEgit As you've probably read already, we won't do more changes here. Ultimately, this is a problem of the capabilities of the fonts installed in the underlying operation system. So it is a little out of the reach for JabRef to do much about it. In newer OSs, Win10 for instance, there seem to be plenty of fonts that can handle Unicode. If you're on Win7, there's Cambria Math that does the trick.

@AEgit
Copy link

AEgit commented Jul 20, 2017

Hmmm, couldn't you just use a font that is already part of the respective operating system (i.e., without installing a new one), that is capable of handling Unicode? So, e.g. in Windows 7, JabRef would default to "Cambria Math" as default font, and in Windows 10 to any other font you mentioned (I'm on Windows 10 so I guess I should have less issues).

@AEgit
Copy link

AEgit commented Jul 20, 2017

Nevermind, I see, that's exactly what you have done in the current development version:
JabRef 4.0-dev--snapshot--2017-07-19--master--2f12fecfb
Windows 10 10.0 amd64
Java 1.8.0_141

Cheers and thank you very much!

@Siedlerchr
Copy link
Member

For summary: LIst of fonts supporting Math Unicode blocks (For MacOS apparently FreeSerif works good)
http://www.fileformat.info/info/unicode/block/mathematical_alphanumeric_symbols/fontsupport.htm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: waiting-for-feedback The submitter or other users need to provide more information about the issue ui
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants