[
https://issues.apache.org/jira/browse/NETBEANS-2463?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16825984#comment-16825984
]
Michal Pudivitr commented on NETBEANS-2463:
-------------------------------------------
It should be the complete list of java "logical fonts"
([https://docs.oracle.com/javase/tutorial/2d/text/fonts.html#logical-fonts])
which seem to be kind of counterparts of the mentioned generic-family names in
CSS.
However, i suppose the _font.getFamily()_ can return physical font as well -
depending on the given font (i'm not sure I fully understand what values can it
assume in the _HtmlPrintContainer_). These should be existing fonts though
while the logical ones are only inside java (and never present on actual system
or understood by browsers).
So, the mapping these five logical fonts and keeping the name as is in other
cases should probably suffice. There may be more elegant way, I'm far from
being someone to tell that. I'd prefer this to be done by someone little more
experienced than me :).
> Print to HTML - wrong font-family
> ---------------------------------
>
> Key: NETBEANS-2463
> URL: https://issues.apache.org/jira/browse/NETBEANS-2463
> Project: NetBeans
> Issue Type: Bug
> Components: editor - Painting & Printing
> Affects Versions: 8.2, 9.0, 10.0, 11.0
> Environment: Windows
> Reporter: Michal Pudivitr
> Priority: Trivial
>
> Using File > Print to HTML will produce HTML with misspelled font family
> (font-family: Monospace{color:#d04437}*d*{color} instead of "monospace"). The
> result is rendered with the browser's default (non-monospace) font.
> Steps to reproduce:
> # Create or open any java file
> # go to File > Print to HTML > Print to file
> # open generated HTML file (result will not be rendered with proper font
> due to wrong font-family)
> # (optional) edit html file replacing all occurrences of "monospace*d*" with
> "monospace" and see the file is now rendered correctly.
> It seems this minor bug was already reported in year 2013 under [Bug
> 236506|https://netbeans.org/bugzilla/show_bug.cgi?id=236506] but the ticked
> was closed unresolved.
> Refer to [https://www.w3.org/Style/Examples/007/fonts] for more about font
> families.
>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists