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

New font PTSans for forms #60

Merged
merged 2 commits into from
Nov 1, 2023
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/de/jost_net/JVerein/gui/control/FormularfeldControl.java
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,10 @@ public SelectInput getFont() throws RemoteException
return font;
}
ArrayList<String> fonts = new ArrayList<>();
fonts.add("PTSans-Regular");
fonts.add("PTSans-Bold");
fonts.add("PTSans-Italic");
fonts.add("PTSans-BoldItalic");
fonts.add("FreeSans");
fonts.add("FreeSans-Bold");
fonts.add("FreeSans-BoldOblique");
Expand Down
3 changes: 3 additions & 0 deletions src/de/jost_net/JVerein/io/FormularAufbereitung.java
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,9 @@ private void goFormularfeld(PdfContentByte contentByte, Formularfeld feld,
filename += feld.getFont().substring(9);
}
bf = BaseFont.createFont(filename+".ttf", BaseFont.IDENTITY_H, true);
} else if (feld.getFont().startsWith("PTSans")) {
String filename = String.format("/fonts/%s.ttf", feld.getFont());
bf = BaseFont.createFont(filename, BaseFont.IDENTITY_H, true);
}
else
{
Expand Down
Binary file added src/fonts/PTSans-Bold.ttf
Binary file not shown.
Binary file added src/fonts/PTSans-BoldItalic.ttf
Binary file not shown.
Binary file added src/fonts/PTSans-Italic.ttf
Binary file not shown.
Binary file added src/fonts/PTSans-Regular.ttf
Binary file not shown.