54 Commits
v1.5 ... 1.7

Author SHA1 Message Date
Minjae Song
9ca70a601b fixing memory leak caused by my sloppy-ass coding 2019-02-07 17:30:15 +09:00
Minjae Song
6cacc56ea8 Update README.md 2019-02-07 03:25:59 +09:00
Minjae Song
6d142f082c readme: gitlab link -> github link 2019-01-29 23:42:20 +09:00
Minjae Song
db3b13800b Merge branch 'cpu-render-pixmap-cache' 2019-01-22 22:39:15 +09:00
Minjae Song
7fe0cc9527 copyright update 2019-01-13 04:42:14 +09:00
Minjae Song
b62fee89cb fixed getWidth() not returning correct width
getWidth() is heavier than ever now, at least it's cached
2019-01-10 20:11:36 +09:00
Minjae Song
d88443814f sheet name comment on coderange, default cache size is 64 2019-01-10 18:25:24 +09:00
Minjae Song
dfeab56bb5 Update CONTRIBUTING.md 2018-12-02 02:35:58 +09:00
Minjae Song
b623727b1a potential memory leak fixed (unbound cache size) 2018-11-03 16:35:26 +09:00
minjaesong
048b683cb2 sorta works but poor performance on wall of text 2018-09-19 02:54:07 +09:00
minjaesong
35b384af53 proper render, except there can be NO transparency in color & spritesheet 2018-09-19 00:07:32 +09:00
minjaesong
cebfa27d59 this is cursed; new shadowing method pls code 2018-09-18 01:08:28 +09:00
minjaesong
c57de3a21f we have a render (but not colour) 2018-09-17 23:10:29 +09:00
minjaesong
4ad5e47758 little diagnose print 2018-09-17 21:29:55 +09:00
Minjae Song
f06ed4529c how the fuck this does not work 2018-09-17 17:51:36 +09:00
Minjae Song
8da321bdc2 fixed bad offset but still bad render 2018-09-17 17:02:09 +09:00
Minjae Song
920b11e3e9 WIP, at least it draws something 2018-09-17 16:26:25 +09:00
minjaesong
d8dd88c6a7 aggressive cacheing (ShittyGlyphLayout) 2018-09-16 18:51:11 +09:00
minjaesong
ba28b6d10c improved shadowing perf at the cost of reduced quality
black text on white background should work now
2018-09-16 16:08:34 +09:00
minjaesong
50ae1789bf this should fix issue #11
If performance is not a concern (which is WIP)
2018-09-16 14:48:02 +09:00
minjaesong
bd9784a516 release candidate 1.7 2018-09-15 16:29:27 +09:00
minjaesong
0bafde9914 latin extended-c 2018-09-10 21:31:00 +09:00
minjaesong
b3bfe6035f support for polytonic greek 2018-09-10 01:26:58 +09:00
minjaesong
c3cf795e9a I still suck at Armenian; polytone greek WIP 2018-09-10 01:02:27 +09:00
minjaesong
cefc7860b3 new armenian (#10)
- Redesigned glyphs
- Update to Unicode 11 (2 chrs added)
2018-09-09 19:51:43 +09:00
minjaesong
b8963cd3a9 full support of old hangul 2018-08-29 00:35:46 +09:00
minjaesong
32290dd504 selectively skipping spritesheets 2018-08-24 02:36:29 +09:00
minjaesong
2702f850c2 elaboration of before-and-after tag; spec change
- RTL tag removed
- we're calling the program part "the font compiler"
2018-08-24 00:37:48 +09:00
minjaesong
2e10249f27 unicode super/subscripts (fractions) 2018-08-23 03:37:22 +09:00
minjaesong
04a375328c fixing up diacritics; complete unipunct 2018-08-22 18:17:48 +09:00
minjaesong
97ef1ddc27 more fucking bengali 2018-08-21 19:54:36 +09:00
minjaesong
4057d86176 more works on IPA
diacritics Overlay and Joiner has implemented
2018-08-14 23:37:29 +09:00
minjaesong
654f7b9ac4 I overwrote the fucking demo text 2018-08-14 19:36:00 +09:00
minjaesong
91afc4af31 tʰɛstɪŋgə tʰɛstɪŋ wʌn tʉ θɹɪ
isOverlay not actually implemented
2018-08-14 19:21:12 +09:00
minjaesong
1440908820 tags definition update to accomodate more weirdness 2018-08-11 04:39:44 +09:00
minjaesong
4ce58cf5d1 made demo program actually run 2018-08-11 00:33:52 +09:00
minjaesong
620794dc57 diacritics overlap artefacts fixed
not as I intended. fuck my life
2018-08-11 00:04:19 +09:00
minjaesong
128eeec6b5 more demotexts (more caps, sanskrit)
about to make substantial changes
2018-08-10 22:18:33 +09:00
minjaesong
33468d5ded impl of georgian mtavruli 2018-08-10 22:00:13 +09:00
minjaesong
96e5bb9a7d bitmap for Georgian Mtavruli (Georgian all-caps) 2018-08-10 21:52:15 +09:00
minjaesong
6300b29ab5 fixed up Thai and Devanagari Anusvara
not perfect but it'll work
2018-08-10 04:20:03 +09:00
minjaesong
a0e2cbf756 Devanagari BETA; broke Thai diacritics again 2018-08-10 01:29:58 +09:00
minjaesong
4a36d3e7f1 bitmap for Devanagari (only) 2018-08-09 21:11:11 +09:00
minjaesong
ab0d483cb1 somehow fixed issue #8 2018-08-09 19:32:30 +09:00
minjaesong
cdd0514ca0 fixed up the test app
- exports the drawn text as demo.PNG
- scrollable with scroll wheels and arrow keys
2018-08-09 17:42:16 +09:00
minjaesong
cf3091421f bringing the shadow back 2018-08-09 15:46:57 +09:00
minjaesong
15fb3d15c0 Kana suppelements and Insular script 2018-08-09 15:34:08 +09:00
minjaesong
45532ca9b7 lemme have some debugging helper 2018-08-09 02:54:43 +09:00
minjaesong
6714bbb510 now everything is converted to UTF-32 internally
- To make working with other planes easier
2018-08-09 02:44:29 +09:00
minjaesong
77f2314b24 stacked diacritics seems working 2018-08-08 13:03:34 +09:00
minjaesong
dcd6390dbf new tagging system (see #5) WIP
- diacritics stacking does not work
- centre align with align-to-this-x-pos is untested
2018-08-08 02:22:40 +09:00
minjaesong
ecac1dc8af contribution guideline on separate md 2018-08-01 08:55:19 +09:00
minjaesong
b3174171c4 Cherokee whitespace adjustments 2018-07-29 07:09:09 +09:00
minjaesong
a0608bf032 README update 2018-07-28 05:48:33 +09:00
45 changed files with 2267 additions and 853 deletions

5
.gitignore vendored
View File

@@ -3,4 +3,7 @@ demo/lib/*
demo/assets/*
out/*
lib/*
Terrarum-sans-bitmap*.zip
Terrarum-sans-bitmap*.zip
TerrarumSansBitmap*.jar
Font*.jar
tmp_*

View File

@@ -9,6 +9,7 @@
</NATIVE>
<SOURCES>
<root url="file://$PROJECT_DIR$/lib" />
<root url="jar://$PROJECT_DIR$/lib/gdx.jar!/" />
</SOURCES>
<jarDirectory url="file://$PROJECT_DIR$/lib" recursive="false" />
<jarDirectory url="file://$PROJECT_DIR$/lib" recursive="false" type="SOURCES" />

549
.idea/workspace.xml generated
View File

@@ -2,17 +2,14 @@
<project version="4">
<component name="ArtifactsWorkspaceSettings">
<artifacts-to-build>
<artifact name="FontDemoGDX" />
<artifact name="TerrarumSansBitmap" />
</artifacts-to-build>
</component>
<component name="ChangeListManager">
<list default="true" id="22c5bc80-996c-4846-b173-7dc8c2096fe3" name="Default" comment="">
<change afterPath="$PROJECT_DIR$/FontTestGDX/META-INF/MANIFEST.MF" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/artifacts/FontDemoGDX.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/artifacts/FontDemoGDX.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/FontTestGDX/demotext.txt" beforeDir="false" afterPath="$PROJECT_DIR$/FontTestGDX/demotext.txt" afterDir="false" />
<change beforePath="$PROJECT_DIR$/FontTestGDX/lib/TerrarumSansBitmap.jar" beforeDir="false" afterPath="$PROJECT_DIR$/FontTestGDX/lib/TerrarumSansBitmap.jar" afterDir="false" />
<change beforePath="$PROJECT_DIR$/demo.PNG" beforeDir="false" afterPath="$PROJECT_DIR$/demo.PNG" afterDir="false" />
<change beforePath="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt" beforeDir="false" afterPath="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt" afterDir="false" />
</list>
<ignored path="$PROJECT_DIR$/out/" />
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
@@ -32,8 +29,29 @@
<file leaf-file-name="GameFontBase.kt" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="568">
<caret line="850" column="12" selection-start-line="850" selection-start-column="12" selection-end-line="850" selection-end-column="12" />
<state relative-caret-position="372">
<caret line="372" lean-forward="true" selection-start-line="372" selection-end-line="372" />
<folding>
<element signature="e#1207#1689#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="TextureRegionPack.kt" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/TextureRegionPack.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="338">
<caret line="50" column="38" selection-start-line="50" selection-start-column="38" selection-end-line="50" selection-end-column="38" />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="GlyphProps.kt" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/GlyphProps.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="91">
<caret line="7" column="22" selection-start-line="7" selection-start-column="22" selection-end-line="7" selection-end-column="22" />
</state>
</provider>
</entry>
@@ -41,8 +59,8 @@
<file leaf-file-name="GameFontBase.kt" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="153">
<caret line="523" column="48" selection-start-line="523" selection-start-column="48" selection-end-line="523" selection-end-column="48" />
<state relative-caret-position="6084">
<caret line="490" selection-start-line="490" selection-end-line="490" />
</state>
</provider>
</entry>
@@ -54,10 +72,10 @@
<file leaf-file-name="FontTestGDX.kt" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/FontTestGDX/src/FontTestGDX.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="483">
<caret line="134" column="40" selection-start-line="134" selection-start-column="40" selection-end-line="134" selection-end-column="40" />
<state relative-caret-position="338">
<caret line="33" column="38" selection-start-line="33" selection-start-column="38" selection-end-line="33" selection-end-column="38" />
<folding>
<element signature="e#48#162#0" expanded="true" />
<element signature="e#0#384#0" expanded="true" />
</folding>
</state>
</provider>
@@ -66,8 +84,61 @@
<file leaf-file-name="GameFontBase.kt" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-242">
<caret line="277" column="5" selection-start-line="277" selection-start-column="5" selection-end-line="277" selection-end-column="5" />
<state relative-caret-position="421">
<caret line="90" column="332" selection-start-line="90" selection-start-column="332" selection-end-line="90" selection-end-column="332" />
<folding>
<element signature="e#1207#1689#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="PixmapRegionPack.kt" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/PixmapRegionPack.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="624">
<caret line="72" column="25" selection-start-line="72" selection-start-column="25" selection-end-line="72" selection-end-column="25" />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="testtext.txt" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/testtext.txt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="117">
<caret line="9" column="91" selection-start-line="9" selection-start-column="91" selection-end-line="9" selection-end-column="91" />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="demotext.txt" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/demotext.txt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="1014">
<caret line="78" column="53" selection-start-line="78" selection-start-column="53" selection-end-line="78" selection-end-column="53" />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="CONTRIBUTING.md" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/CONTRIBUTING.md">
<provider selected="true" editor-type-id="split-provider[text-editor;MarkdownPreviewEditor]">
<state split_layout="FIRST">
<first_editor relative-caret-position="1235">
<caret line="95" column="30" selection-start-line="95" selection-start-column="30" selection-end-line="95" selection-end-column="30" />
</first_editor>
<second_editor>
<js_state />
</second_editor>
</state>
</provider>
</entry>
</file>
<file leaf-file-name="CONTRIBUTORS.txt" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/CONTRIBUTORS.txt">
<provider selected="true" editor-type-id="text-editor">
<state>
<caret column="23" selection-start-column="23" selection-end-column="23" />
</state>
</provider>
</entry>
@@ -76,8 +147,8 @@
<entry file="file://$PROJECT_DIR$/README.md">
<provider selected="true" editor-type-id="split-provider[text-editor;MarkdownPreviewEditor]">
<state split_layout="FIRST">
<first_editor relative-caret-position="631">
<caret line="241" column="171" selection-start-line="241" selection-start-column="171" selection-end-line="241" selection-end-column="171" />
<first_editor relative-caret-position="143">
<caret line="11" column="175" selection-start-line="11" selection-start-column="175" selection-end-line="11" selection-end-column="175" />
</first_editor>
<second_editor>
<js_state />
@@ -94,37 +165,50 @@
<option name="RECENT_TEMPLATES">
<list>
<option value="Kotlin Class" />
<option value="Interface" />
<option value="Class" />
</list>
</option>
</component>
<component name="FindInProjectRecents">
<findStrings>
<find>getG</find>
<find>getWidt</find>
<find>batch.color =</find>
<find>isXYSwapped</find>
<find>xySw</find>
<find>getWidth</find>
<find>f</find>
<find>fun getWidth</find>
<find>fun dispo</find>
<find>xHei</find>
<find>not copy</find>
<find>getColour</find>
<find>.094</find>
<find>ө</find>
<find>ď</find>
<find>ñ</find>
<find>fun relo</find>
<find>getSheetT</find>
<find>Unexpected</find>
<find>Unexp</find>
<find>fun getSh</find>
<find>codeRange</find>
<find>isHangul</find>
<find></find>
<find>toColo</find>
<find>getWidthOfCharSeq</find>
<find>makeShadow</find>
<find>glyphWidthBuffer</find>
<find>oldCharSequence</find>
<find>charSeq.toCodeP</find>
<find>resetH</find>
<find>HashMap</find>
<find>drawPixmap</find>
<find>RGBA</find>
<find>makeShado</find>
<find>pixmapHolder</find>
<find>isColourCode</find>
<find>makeSha</find>
<find>toRGBA</find>
<find>posXbuff</find>
<find>buildWidthAndPos</find>
<find>flagMake</find>
<find>pixmapHolder?.dis</find>
<find>glyphProps[</find>
<find>textCache</find>
<find>glyphProps</find>
<find>(c: Int)</find>
<find>hashC</find>
<find>TreeNode</find>
<find>sear</find>
<find>fun draw</find>
<find>println</find>
</findStrings>
<replaceStrings>
<replace>.141</replace>
<replace>c</replace>
<replace>har</replace>
<replace>TEXH</replace>
<replace>(c: CodePoint)</replace>
</replaceStrings>
</component>
<component name="Git.Settings">
@@ -138,27 +222,36 @@
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/testbed/FontTest.kt" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/testbed/FontTestGDX.kt" />
<option value="$PROJECT_DIR$/LICENSE.md" />
<option value="$PROJECT_DIR$/README.md" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt" />
<option value="$PROJECT_DIR$/FontTestGDX/src/FontTestGDX.kt" />
<option value="$PROJECT_DIR$/FontTestGDX/demotext.txt" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/GameFontBase.kt" />
<option value="$PROJECT_DIR$/CONTRIBUTORS.txt" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/GlyphProps.kt" />
<option value="$PROJECT_DIR$/README.md" />
<option value="$PROJECT_DIR$/testtext.txt" />
<option value="$PROJECT_DIR$/FontTestGDX/src/FontTestGDX.kt" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/TextureRegionPack.kt" />
<option value="$PROJECT_DIR$/CONTRIBUTING.md" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/PixmapRegionPack.kt" />
<option value="$PROJECT_DIR$/demotext.txt" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/AgedItem.java" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/RedBlackNode.java" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/RedBlackTree.java" />
<option value="$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt" />
</list>
</option>
</component>
<component name="ProjectFrameBounds" extendedState="6">
<option name="x" value="1912" />
<option name="y" value="-521" />
<option name="x" value="-8" />
<option name="y" value="-8" />
<option name="width" value="1936" />
<option name="height" value="1176" />
<option name="height" value="1216" />
</component>
<component name="ProjectView">
<navigator proportions="" version="1">
<foldersAlwaysOnTop value="true" />
</navigator>
<panes>
<pane id="PackagesPane" />
<pane id="Scope" />
<pane id="ProjectPane">
<subPane>
<expand>
@@ -188,22 +281,33 @@
<item name="src" type="462c0819:PsiDirectoryNode" />
<item name="terrarumsansbitmap" type="462c0819:PsiDirectoryNode" />
</path>
<path>
<item name="BuildJAR_TerrarumSansBitmap" type="b2602c69:ProjectViewProjectNode" />
<item name="Terrarum-sans-bitmap" type="462c0819:PsiDirectoryNode" />
<item name="src" type="462c0819:PsiDirectoryNode" />
<item name="terrarumsansbitmap" type="462c0819:PsiDirectoryNode" />
<item name="gdx" type="462c0819:PsiDirectoryNode" />
</path>
</expand>
<select />
</subPane>
</pane>
<pane id="PackagesPane" />
<pane id="Scope" />
</panes>
</component>
<component name="PropertiesComponent">
<property name="SearchEverywhereHistoryKey" value="soft wr&#9;ACTION&#9;EditorToggleUseSoftWraps" />
<property name="last_opened_file_path" value="$PROJECT_DIR$/FontTestGDX" />
<property name="SearchEverywhereHistoryKey" value="HashMap&#9;PSI&#9;JAVA://java.util.HashMap&#10;soft wr&#9;ACTION&#9;EditorToggleUseSoftWraps" />
<property name="last_opened_file_path" value="$PROJECT_DIR$/lib/gdx.jar!/" />
<property name="project.structure.last.edited" value="Artifacts" />
<property name="project.structure.proportion" value="0.15" />
<property name="project.structure.side.proportion" value="0.32068965" />
<property name="settings.editor.selected.configurable" value="preferences.lookFeel" />
<property name="settings.editor.selected.configurable" value="preferences.language.Kotlin" />
</component>
<component name="RecentsManager">
<key name="MoveFile.RECENT_KEYS">
<recent name="C:\Users\minjaesong\Documents\Terrarum-sans-bitmap\" />
<recent name="C:\Users\minjaesong\Documents\Terrarum-sans-bitmap" />
<recent name="C:\Users\minjaesong\Documents\Terrarum-sans-bitmap\FontTestGDX\src" />
</key>
</component>
@@ -258,6 +362,16 @@
<option name="Make" enabled="true" />
</method>
</configuration>
<configuration default="true" type="JetRunConfigurationType" factoryName="Kotlin">
<module name="BuildJAR_TerrarumSansBitmap" />
<option name="VM_PARAMETERS" />
<option name="PROGRAM_PARAMETERS" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PASS_PARENT_ENVS" value="true" />
<option name="MAIN_CLASS_NAME" />
<option name="WORKING_DIRECTORY" />
</configuration>
<configuration default="true" type="KotlinStandaloneScriptRunConfigurationType" factoryName="Kotlin script">
<option name="filePath" />
<option name="vmParameters" />
@@ -348,19 +462,6 @@
<envs />
<method />
</configuration>
<configuration default="true" type="JetRunConfigurationType" factoryName="Kotlin">
<extension name="coverage" enabled="false" merge="false" sample_coverage="true" runner="idea" />
<option name="MAIN_CLASS_NAME" />
<option name="VM_PARAMETERS" />
<option name="PROGRAM_PARAMETERS" />
<option name="WORKING_DIRECTORY" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
<option name="ALTERNATIVE_JRE_PATH" />
<option name="PASS_PARENT_ENVS" value="true" />
<module name="BuildJAR_TerrarumSansBitmap" />
<envs />
<method />
</configuration>
<configuration default="true" type="Remote" factoryName="Remote">
<option name="USE_SOCKET_TRANSPORT" value="true" />
<option name="SERVER_MODE" value="false" />
@@ -416,31 +517,31 @@
</todo-panel>
</component>
<component name="ToolWindowManager">
<frame x="1912" y="-521" width="1936" height="1176" extended-state="6" />
<frame x="-8" y="-8" width="1936" height="1216" extended-state="6" />
<editor active="true" />
<layout>
<window_info anchor="right" id="Palette" order="3" />
<window_info anchor="bottom" id="TODO" order="6" />
<window_info anchor="bottom" id="Messages" order="7" weight="0.32851636" />
<window_info anchor="right" id="Palette&#9;" order="3" />
<window_info anchor="bottom" id="Event Log" order="7" side_tool="true" />
<window_info anchor="right" id="Maven Projects" order="3" />
<window_info anchor="bottom" id="Messages" order="9" visible="true" weight="0.20779221" />
<window_info anchor="right" id="Palette&#9;" order="5" />
<window_info anchor="bottom" id="Event Log" order="10" side_tool="true" />
<window_info anchor="right" id="Maven Projects" order="4" />
<window_info anchor="bottom" id="Run" order="2" weight="0.2591522" />
<window_info anchor="bottom" id="Version Control" order="7" />
<window_info anchor="bottom" id="Version Control" order="8" />
<window_info anchor="bottom" id="Terminal" order="7" />
<window_info id="Designer" order="2" />
<window_info content_ui="combo" id="Project" order="0" visible="true" weight="0.12953092" />
<window_info active="true" content_ui="combo" id="Project" order="0" visible="true" weight="0.09008529" />
<window_info anchor="bottom" id="Find" order="1" weight="0.32931355" />
<window_info id="Structure" order="1" side_tool="true" weight="0.25" />
<window_info anchor="right" id="Ant Build" order="1" weight="0.25" />
<window_info id="UI Designer" order="2" />
<window_info active="true" anchor="bottom" id="Debug" order="3" visible="true" weight="0.23025048" />
<window_info id="Favorites" order="2" side_tool="true" />
<window_info id="UI Designer" order="4" />
<window_info anchor="bottom" id="Debug" order="3" weight="0.24768089" />
<window_info id="Favorites" order="3" side_tool="true" />
<window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
<window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
<window_info anchor="right" id="Commander" order="0" weight="0.4" />
<window_info anchor="bottom" id="Message" order="0" />
<window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />
<window_info anchor="bottom" id="Find" order="1" />
</layout>
</component>
<component name="VcsContentAnnotationSettings">
@@ -456,13 +557,6 @@
<option name="FILTER_TARGETS" value="false" />
</component>
<component name="editorHistoryManager">
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8905">
<caret line="749" column="35" selection-start-line="749" selection-start-column="35" selection-end-line="749" selection-end-column="35" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="9594">
@@ -477,9 +571,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="4940">
@@ -487,9 +578,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="5148">
@@ -497,9 +585,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="4752">
@@ -507,9 +592,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="7692">
@@ -517,8 +599,12 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8974">
<caret line="704" column="13" selection-start-line="704" selection-start-column="13" selection-end-line="704" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
@@ -527,8 +613,12 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8974">
<caret line="704" column="13" selection-start-line="704" selection-start-column="13" selection-end-line="704" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
@@ -537,9 +627,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8974">
@@ -547,9 +634,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8974">
@@ -557,29 +641,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8974">
<caret line="704" column="13" selection-start-line="704" selection-start-column="13" selection-end-line="704" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8974">
<caret line="704" column="13" selection-start-line="704" selection-start-column="13" selection-end-line="704" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="112">
@@ -608,9 +669,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="504">
@@ -618,9 +676,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="532">
@@ -635,16 +690,78 @@
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/slick.jar!/org/newdawn/slick/Color.class">
<entry file="jar://$PROJECT_DIR$/lib/slick.jar!/org/newdawn/slick/Color.class" />
<entry file="jar://$PROJECT_DIR$/FontTestGDX/lib/TerrarumSansBitmap.jar!/net/torvald/terrarumsansbitmap/gdx/GameFontBase.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="339">
<caret line="76" column="11" selection-start-line="76" selection-start-column="11" selection-end-line="76" selection-end-column="11" />
<state relative-caret-position="513">
<caret line="308" column="21" selection-start-line="308" selection-start-column="21" selection-end-line="308" selection-end-column="21" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/LICENSE.md">
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/readme.md">
<provider selected="true" editor-type-id="split-provider[text-editor;MarkdownPreviewEditor]">
<state split_layout="SPLIT">
<first_editor />
<second_editor>
<js_state />
</second_editor>
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/gdx.jar!/com/badlogic/gdx/graphics/g2d/GlyphLayout.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="156">
<caret line="23" column="11" selection-start-line="23" selection-start-column="11" selection-end-line="23" selection-end-column="11" />
</state>
</provider>
</entry>
<entry file="jar://C:/Program Files/Java/jdk1.8.0_131/src.zip!/java/lang/Character.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="515">
<caret line="4839" column="59" selection-start-line="4837" selection-start-column="15" selection-end-line="4839" selection-end-column="59" />
</state>
</provider>
</entry>
<entry file="jar://C:/Program Files/Java/jdk1.8.0_131/src.zip!/java/lang/CharSequence.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="509">
<caret line="219" column="49" selection-start-line="219" selection-start-column="49" selection-end-line="219" selection-end-column="49" />
</state>
</provider>
</entry>
<entry file="jar://$KOTLIN_BUNDLED$/lib/kotlin-runtime-sources.jar!/kotlin/CharSequence.kt" />
<entry file="jar://$PROJECT_DIR$/lib/gdx.jar!/com/badlogic/gdx/graphics/glutils/GLFrameBuffer.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="2379">
<caret line="205" column="13" selection-start-line="205" selection-start-column="13" selection-end-line="205" selection-end-column="13" />
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/FontTestGDX/lib/TerrarumSansBitmap.jar!/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="390">
<caret line="448" column="21" lean-forward="true" selection-start-line="448" selection-start-column="21" selection-end-line="448" selection-end-column="21" />
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/gdx.jar!/com/badlogic/gdx/utils/ScreenUtils.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="272">
<caret line="38" column="25" selection-start-line="38" selection-start-column="25" selection-end-line="38" selection-end-column="25" />
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/gdx.jar!/com/badlogic/gdx/files/FileHandle.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="260">
<caret line="118" column="39" selection-start-line="118" selection-start-column="32" selection-end-line="118" selection-end-column="39" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/GameFontBase.kt" />
<entry file="file://$PROJECT_DIR$/LICENSE.md">
<provider selected="true" editor-type-id="split-provider[text-editor;MarkdownPreviewEditor]">
<state split_layout="FIRST">
<first_editor relative-caret-position="26">
<caret line="2" column="23" selection-start-line="2" selection-start-column="23" selection-end-line="2" selection-end-column="23" />
</first_editor>
@@ -654,21 +771,11 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="153">
<caret line="523" column="48" selection-start-line="523" selection-start-column="48" selection-end-line="523" selection-end-column="48" />
</state>
</provider>
</entry>
<entry file="file://$USER_HOME$/AppData/Local/Temp/Ихадоу адаҟьа.URL">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/README.md">
<provider selected="true" editor-type-id="split-provider[text-editor;MarkdownPreviewEditor]">
<state split_layout="FIRST">
<first_editor relative-caret-position="631">
<caret line="241" column="171" selection-start-line="241" selection-start-column="171" selection-end-line="241" selection-end-column="171" />
<first_editor relative-caret-position="143">
<caret line="11" column="175" selection-start-line="11" selection-start-column="175" selection-end-line="11" selection-end-column="175" />
</first_editor>
<second_editor>
<js_state />
@@ -676,34 +783,151 @@
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/FontTestGDX/lib/TerrarumSansBitmap.jar!/net/torvald/terrarumsansbitmap/gdx/GameFontBase.class">
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/slick2d/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="513">
<caret line="308" column="21" selection-start-line="308" selection-start-column="21" selection-end-line="308" selection-end-column="21" />
<state relative-caret-position="6084">
<caret line="490" selection-start-line="490" selection-end-line="490" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/GlyphProps.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="91">
<caret line="7" column="22" selection-start-line="7" selection-start-column="22" selection-end-line="7" selection-end-column="22" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/CONTRIBUTORS.txt">
<provider selected="true" editor-type-id="text-editor">
<state>
<caret column="23" selection-start-column="23" selection-end-column="23" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/CONTRIBUTING.md">
<provider selected="true" editor-type-id="split-provider[text-editor;MarkdownPreviewEditor]">
<state split_layout="FIRST">
<first_editor relative-caret-position="1235">
<caret line="95" column="30" selection-start-line="95" selection-start-column="30" selection-end-line="95" selection-end-column="30" />
</first_editor>
<second_editor>
<js_state />
</second_editor>
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/gdx.jar!/com/badlogic/gdx/graphics/g2d/Gdx2DPixmap.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="356">
<caret line="152" column="16" selection-start-line="152" selection-start-column="16" selection-end-line="152" selection-end-column="16" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/TextureRegionPack.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="338">
<caret line="50" column="38" selection-start-line="50" selection-start-column="38" selection-end-line="50" selection-end-column="38" />
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/gdx-backend-lwjgl.jar!/com/badlogic/gdx/backends/lwjgl/LwjglApplication.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="501">
<caret line="277" column="9" lean-forward="true" selection-start-line="277" selection-start-column="9" selection-end-line="277" selection-end-column="9" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/PixmapRegionPack.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="624">
<caret line="72" column="25" selection-start-line="72" selection-start-column="25" selection-end-line="72" selection-end-column="25" />
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/gdx.jar!/com/badlogic/gdx/graphics/Pixmap.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="356">
<caret line="118" column="15" selection-start-line="118" selection-start-column="15" selection-end-line="118" selection-end-column="15" />
</state>
</provider>
</entry>
<entry file="jar://$PROJECT_DIR$/lib/gdx.jar!/com/badlogic/gdx/graphics/Color.class">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="262">
<caret line="52" column="11" selection-start-line="52" selection-start-column="11" selection-end-line="52" selection-end-column="11" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/FontTestGDX/src/FontTestGDX.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="483">
<caret line="134" column="40" selection-start-line="134" selection-start-column="40" selection-end-line="134" selection-end-column="40" />
<state relative-caret-position="338">
<caret line="33" column="38" selection-start-line="33" selection-start-column="38" selection-end-line="33" selection-end-column="38" />
<folding>
<element signature="e#48#162#0" expanded="true" />
<element signature="e#0#384#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/FontTestGDX/demotext.txt">
<entry file="file://$PROJECT_DIR$/demotext.txt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="299">
<caret line="23" lean-forward="true" selection-start-line="23" selection-end-line="23" />
<state relative-caret-position="1014">
<caret line="78" column="53" selection-start-line="78" selection-start-column="53" selection-end-line="78" selection-end-column="53" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/testtext.txt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="117">
<caret line="9" column="91" selection-start-line="9" selection-start-column="91" selection-end-line="9" selection-end-column="91" />
</state>
</provider>
</entry>
<entry file="jar://C:/Program Files/Java/jdk1.8.0_131/src.zip!/java/util/HashMap.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-5975">
<caret line="1798" column="23" selection-start-line="1798" selection-start-column="23" selection-end-line="1798" selection-end-column="23" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/AgedItem.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="325">
<caret line="25" column="1" selection-start-line="25" selection-start-column="1" selection-end-line="25" selection-end-column="1" />
<folding>
<element signature="e#309#310#0" expanded="true" />
<element signature="e#335#336#0" expanded="true" />
<element signature="e#462#463#0" expanded="true" />
<element signature="e#486#487#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/RedBlackNode.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="351">
<caret line="27" column="14" selection-start-line="27" selection-start-column="14" selection-end-line="27" selection-end-column="14" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/RedBlackTree.java">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-9212">
<caret line="69" column="67" selection-start-line="69" selection-start-column="67" selection-end-line="69" selection-end-column="67" />
<folding>
<element signature="imports" expanded="true" />
<element signature="e#22666#22667#0" expanded="true" />
<element signature="e#22707#22708#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/src/net/torvald/terrarumsansbitmap/gdx/GameFontBase.kt">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-242">
<caret line="277" column="5" selection-start-line="277" selection-start-column="5" selection-end-line="277" selection-end-column="5" />
<state relative-caret-position="372">
<caret line="372" lean-forward="true" selection-start-line="372" selection-end-line="372" />
<folding>
<element signature="e#1207#1689#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
@@ -713,7 +937,7 @@
<state key="ArtifactsStructureConfigurable.UI">
<settings>
<artifact-editor />
<last-edited>FontDemoGDX</last-edited>
<last-edited>TerrarumSansBitmap</last-edited>
<splitter-proportions>
<option name="proportions">
<list>
@@ -741,7 +965,7 @@
<splitter-proportions>
<option name="proportions">
<list>
<option value="0.2" />
<option value="0.32068965" />
</list>
</option>
</splitter-proportions>
@@ -753,7 +977,7 @@
<splitter-proportions>
<option name="proportions">
<list>
<option value="0.2" />
<option value="0.32068965" />
</list>
</option>
</splitter-proportions>
@@ -766,6 +990,7 @@
<option name="proportions">
<list>
<option value="0.32068965" />
<option value="0.6" />
</list>
</option>
</splitter-proportions>
@@ -773,7 +998,7 @@
</state>
<state key="ProjectLibrariesConfigurable.UI">
<settings>
<last-edited>TesterLib</last-edited>
<last-edited>GdxLib</last-edited>
<splitter-proportions>
<option name="proportions">
<list>

182
CONTRIBUTING.md Normal file
View File

@@ -0,0 +1,182 @@
#### Pixel Artists Wanted: for Arabic (all four forms) and other Indian scripts (all the ligatures). Must willing to follow the styles and have a knowledge in Unicode. Your name will be inscribed in the list of contributors.
You can contribute to the font by fixing wrong glyphs, suggesting better ones, extending character set (letters for other writing systems or filling in the blanks on the existing ones), or code for other game frameworks (not limited to Java). Please leave pull request for that.
Font Spritesheets are stored in ```assets/graphics/fonts``` directory. Image format must be TGA with Alpha — no PNG. If someone needs PNG, they can batch-convert the font using utils like ImageMagick.
#### Before getting started, you did read our design goals, right? Good. Now you may continue your awesome work.
### Ascenders, descenders, width informations (aka Glyph Tags)
![Alas, use more modern browser or get better internet connexion!](glyph_height_pos_annotation.png)
Above image is a reference you can use while you draw some letters. Capital B is drawn as a reference. Orange-tinted area is for lowercase, x-height must be the same as that of said tinted area (lowercase Alpha is also drawn for the reference). NOTE THAT x-height is taller than centre bar (capital A is an exception). Height of the ascender of the lowercase letters must be the same as height of capital letters.
Red-tinted area SHOULD NOT CONTAIN any dots, it's emptied for compatibility. (Slick2d—you can define size of "gaps" of the spritesheet, but you can't define horizontal and vertical gap separately)
Blue-tinted area cotains width of the glyph in binary, uppermost dot is the Least Significant Bit.
Green-tinted area contains extra informations, left blank for most cases. We'll call it Glyph Tags.
Tinted-in-magenta shows the height where diacritics should be placed, for both uppercase and lowercase.
Each cell is 16 px wide, and any glyph you draw **must be contained within leftside FIFTEEN pixels**.
### Font Metrics
Although the font is basically a Spritesheet, some of the sheet expects variable widths to be supported. Any sheets with ```_variable``` means it expects variable widths. Anything else expects fixed width (regular Spritesheet behaviour). ```cjkpunct``` has width of 10, ```kana``` and ```hangul_johab``` has width of 12, ```wenquanyi``` has width of 16.
### Parsing glyph widths for variable font sheets
![Sample of Font Spritesheet with annotation](width_bit_encoding_annotated.png)
Width is encoded in binary bits, on pixels. On the font spritesheet, every glyph has vertical dots on their top-right side (to be exact, every (16k - 1)th pixel on x axis). Above image is a sample of the font, with width information coloured in magenta. From top to bottom, each dot represents 1, 2, 4 and 8. For example, in the above image, ! (exclamation mark) has width of 5, " (double quote) has width of 6, # (octothorp) has width of 8, $ (dollar sign) has width of 9.
### Glyph Tags
Green-tinted area (should be 10 px tall) contains the tags. Tags are defined as following:
```
(LSB) 0 == Use Compiler Directive (Undefined right now, keep it as 0)
1 -, 1 = Align to this X pos of prev char,
1 | 2 = only valid if write-on-top is 1
1 | 4 = and is centre-aligned and non-zero
1 -' 8 = (if this is zero, floorOf(width/2) will be used instead)
0 -, 0 Align 1 Align 0 Align 1 Align before
1 -' 0 left 0 right 1 centre 1 the glyph
1 == write-on-top, usually it's diatritics but not always (e.g. devanagari vowel sign O)
1 -, 0 Stack 1 Stack 0 Before 1 Up &
(MSB) 0 -' 0 up 0 down 1 &After 1 Down (e.g. U+0C48)
```
#### Stack Up/Down
When the tag is stack-up, it'll be drawn 4 px lower if the underlying
character is lowercase.
#### Align-To-This-X-Pos
Since this tag does not make sense for diacritics, they will use the value for compeletely different purpose:
0 : Nothing special
1 : Covers previous character; it's neither stack-up nor down.
Will be drawn 2 px lower if the underlying character is lowercase
2 : Joiner.
3..15: undefined
#### Diacritics That Comes Before and After
When this tag is set, the font compiler will replace this glyph with two extra code points given in the bitmap.
To implement those, this two extra code points are needed, which are provided in the Unicode's Reference Chart (www.unicode.org/charts/PDF/Uxxxx.pdf) The code points must be "drawn" in the bitmap, in the same manor as a tagging system. The zeroth column (x = 0) has the "before" character, the first column (x = 1) has the "after". All nineteen pixels (bits) are read by the font, which encompasses U+0000..U+EFFFF
For working examples, take a note at the bengali sprite sheet.
This tag can be used as a general "replace this with these" directive, as long as you're replacing it into two letters. This directive is exploited to construct dutch ligature "IJ" (U+0132 and U+0133), in the sheet LatinExtA.
Also note that the font compiler will not "stack" these diacritics.
#### NOTES
- If glyphs are right or centre aligned, they must be aligned in the same way inside of the bitmap; the font compiler assumes every variable-width glyphs to have a width of 15, regardless of the tagged width.
- If the diacritic is aligned before the glyph, the diacritic itself is always assumed as left-aligned, as the font compiler will exchange position of said diacritic and the glyph right before it.
![Visual representation of left/right/centre align](alignment_illustration.jpg)
(fun fact: it was drawn on Rhodia memopad with Lamy 2000, then photographed and edited on my iPhone. Letter used is a Cherokee WE Ꮺ)
### Technical Limitations
- Each spritesheet is 4096x4096 maximum, which is a size of 4K Texture. However it is recommended to be smaller or equal to 1024x1024.
- Glyphs exceeding 15px of width needs to be broken down with 2 or more characters. Wider sheets WILL NOT BE IMPLEMENTED, can't waste much pixels just for few superwide glyphs.
- Due to how the compiler is coded, actual glyph must have alpha value of 255, the tags must have alpha values LESS THAN 255 (and obviously greater than zero). RGB plane of the TGA image doesn't do anything, keep it as #FFFFFF white.
### Implementing the Korean writing system
On this font, Hangul letters are printed by assemblying two or three letter pieces. There are 10 sets of Hangul letter pieces on the font. Top 6 are initials, middle 2 are medials, and bottom 2 are finals. On the rightmost side, there's eight assembled glyphs to help you with (assuming you have basic knowledge on the writing system). Top 6 tells you how to use 6 initials, and bottom 2 tells you how to use 2 finals.
This is a Kotlin-like pseudocode for assembling the glyph:
// NOTE: this code implements modern Hangul only, in the unicode range of 0xAC00..0xD7A3.
// the spritesheet is made to accomodate Johab encoding scheme, but can still be used with the following code.
// for the code for full Johab encoding (U+1100.. that includes Old Korean), please refer to the actual code in the repo.
function getHanChosung(hanIndex: Int) = hanIndex / (21 * 28)
function getHanJungseong(hanIndex: Int) = hanIndex / 28 % 21
function getHanJongseong(hanIndex: Int) = hanIndex % 28
jungseongWide = arrayOf(9,13,14,18,19)
jungseongComplex = arrayOf(10,11,12,15,16,17,20,23)
function getHanInitialRow(hanIndex: Int): Int {
val ret: Int
if (isJungseongWide(hanIndex))
ret = 2
else if (isJungseongComplex(hanIndex))
ret = 4
else
ret = 0
return if (getHanJongseong(hanIndex) == 0) ret else ret + 1
}
function isJungseongWide(hanIndex: Int) = jungseongWide.contains(getHanJungseong(hanIndex))
function isJungseongComplex(hanIndex: Int) = jungseongComplex.contains(getHanJungseong(hanIndex))
function getHanInitialRow(hanIndex: Int): Int {
val ret: Int
if (isJungseongWide(hanIndex))
ret = 2
else if (isJungseongComplex(hanIndex))
ret = 4
else
ret = 0
return if (getHanJongseong(hanIndex) == 0) ret else ret + 1
}
function getHanMedialRow(hanIndex: Int) = if (getHanJongseong(hanIndex) == 0) 6 else 7
function getHanFinalRow(hanIndex: Int): Int {
val jungseongIndex = getHanJungseong(hanIndex)
return if (jungseongWide.contains(jungseongIndex))
8
else
9
}
function isHangul(c: Char) = c.toInt() >= 0xAC00 && c.toInt() < 0xD7A4
...
for (each Char on the string) {
if (isHangul(Char)) {
val hIndex = Char.toInt() - 0xAC00
val indexCho = getHanChosung(hIndex)
val indexJung = getHanJungseong(hIndex)
val indexJong = getHanJongseong(hIndex)
val choRow = getHanInitialRow(hIndex)
val jungRow = getHanMedialRow(hIndex)
val jongRow = getHanFinalRow(hIndex)
// get sub image from sprite sheet
val choseongImage = hangulSheet.getSubImage(indexCho, choRow)
val jungseongImage = hangulSheet.getSubImage(indexJung, jungRow)
val jongseongImage = hangulSheet.getSubImage(indexJong, jongRow)
// actual drawing part
draw choseongImage to somewhere you want
draw jungseongImage on top of choseongImage
draw jongseongImage on top of choseongImage
}
...
}

9
CONTRIBUTORS.txt Normal file
View File

@@ -0,0 +1,9 @@
Project Maintainer and Programmer
- minjaesong (Torvald)
This font was not possible without following artists:
- minjaesong (Torvald)
<< Append your name here. If you're getting consistent merge conflicts, push without this and leave a Issue on the GitHub page >>

Binary file not shown.

View File

@@ -1,95 +0,0 @@
􏿆The bitmap font for games developers who seek good font that has real multilingual support,􀀀
􏿆for free (as in freedom and without cost)􀀀
There are many bitmap fonts on the internet. You care for the multilingual support, but alas!
most of them do not support your language, vector fonts take too much time to load, and even
then their legibility suffers because fuck built-in antialias.
You somehow found a multilingual one, and it makes your game look like an old computer, and you say:
“Well, better than nothing… no, its ugly.”
You speak japanese and you wish to support it, but then このクソなfont only goot for displaying
Japanese, it's not even multilingual, and their English look uncanny and inconsistent as hell.
Eventually you just mix different fonts together, and the results were always infuriating.
No more suffering. This font has everything you need.
􏾐while􀀀 (isVisible(􏺟BAD_FONTS􀀀)) {
ripAndTear(􏺟BAD_FONTS􀀀).where { 􏺟GUTS􀀀 };
}
How multilingual? Real multilingual!
􌿽Ианҵоуп ақьаад, нусхур аҩырала, ҩ ҽшьаҟакла, иҧшӡоу анапҩырала􀀀
􌿽Գրիչս վայր դրի, վեր կացա և պատրաստվում էի, որ քնեմ, երբ հանկարծ դռանս զանգակը հնչեց􀀀
􌿽Zəfər, jaketini də papağını da götür, bu axşam hava çox soyuq olacaq􀀀
􌿽󿿹Под южно дърво, цъфтящо в синьо, бягаше малко пухкаво зайче󿿸􀀀
􌿽ᎠᏍᎦᏯᎡᎦᎢᎾᎨᎢᎣᏍᏓᎤᎩᏍᏗᎥᎴᏓᎯᎲᎢᏔᎵᏕᎦᏟᏗᏖᎸᎳᏗᏗᎧᎵᎢᏘᎴᎩ ᏙᏱᏗᏜᏫᏗᏣᏚᎦᏫᏛᏄᏓᎦᏝᏃᎠᎾᏗᎭᏞᎦᎯᎦᏘᏓᏠᎨᏏᏕᏡᎬᏢᏓᏥᏩᏝᎡᎢᎪᎢ􀀀
􌿽ᎠᎦᏂᏗᎮᎢᎫᎩᎬᏩᎴᎢᎠᏆᏅᏛᎫᏊᎾᎥᎠᏁᏙᎲᏐᏈᎵᎤᎩᎸᏓᏭᎷᏤᎢᏏᏉᏯᏌᏊ ᎤᏂᏋᎢᏡᎬᎢᎰᏩᎬᏤᎵᏍᏗᏱᎩᎱᎱᎤᎩᎴᎢᏦᎢᎠᏂᏧᏣᏨᎦᏥᎪᎥᏌᏊᎤᎶᏒᎢᎢᏡᎬᎢ􀀀
􌿽ᎹᎦᎺᎵᏥᎻᎼᏏᎽᏗᏩᏂᎦᏘᎾᎿᎠᏁᎬᎢᏅᎩᎾᏂᎡᎢᏌᎶᎵᏎᎷᎠᏑᏍᏗᏪᎩ ᎠᎴ ᏬᏗᏲᏭᎾᏓᏍᏓᏴᏁᎢᎤᎦᏅᏮᏰᎵᏳᏂᎨᎢ􀀀
􌿽Příliš žluťoučký kůň úpěl ďábelské ódy􀀀
􌿽Quizdeltagerne spiste jordbær med fløde, mens cirkusklovnen Walther spillede på xylofon􀀀
􌿽Victor jagt zwölf Boxkämpfer quer über den großen Sylter Deich􀀀
􌿽διαφυλάξτε γενικά τη ζωή σας από βαθειά ψυχικά τραύματα􀀀
􌿽ΔΙΑΦΥΛΆΞΤΕ ΓΕΝΙΚΆ ΤΗ ΖΩΉ ΣΑΣ ΑΠΌ ΒΑΘΕΙΆ ΨΥΧΙΚΆ ΤΡΑΎΜΑΤΑ􀀀
􌿽სწრაფი ყავისფერი მელა გადაახტა ზარმაც ძაღლს􀀀
􌿽Kæmi ný öxi hér, ykist þjófum nú bæði víl og ádrepa􀀀
􌿽Ċuaiġ bé ṁórṡáċ le dlúṫspád fíorḟinn trí hata mo ḋea-ṗorcáin ḃig􀀀
􌿽とりなくこゑす ゆめさませ みよあけわたる ひんかしを そらいろはえて おきつへに ほふねむれゐぬ もやのうち􀀀
􌿽田居に出で 菜摘むわれをぞ 君召すと 求食り追ひゆく 山城の 打酔へる子ら 藻葉干せよ え舟繋けぬ􀀀
􌿽정 참판 양반댁 규수 큰 교자 타고 혼례 치른 날 하얬다 도럄직한 퀡봹퉪헰􀀀
􌿽Četri psihi faķīri vēlu vakarā zāģēja guļbūvei durvis, fonā šņācot mežam􀀀
􌿽Įlinkdama fechtuotojo špaga sublykčiojusi pragręžė apvalų arbūzą􀀀
􌿽Ѕидарски пејзаж: шугав билмез со чудење џвака ќофте и кељ на туѓ цех􀀀
􌿽Щётканы фермд пийшин цувъя. Бөгж зогсч хэльюү􀀀
􌿽Pchnąć w tę łódź jeża lub ośm skrzyń fig􀀀
􌿽Înjurând pițigăiat, zoofobul comandă vexat whisky și tequila􀀀
􌿽Широкая электрификация южных губерний даст мощный толчок подъёму сельского хозяйства􀀀
􌿽󿿺Ајшо, лепото и чежњо, за љубав срца мога дођи у Хаџиће на кафу󿿸􀀀
􌿽Jovencillo emponzoñado de whisky: ¡qué figurota exhibe!􀀀
􌿽นายสังฆภัณฑ์ เฮงพิทักษ์ฝั่ง ผู้เฒ่าซึ่งมีอาชีพเป็นฅนขายฃวด ถูกตำรวจปฏิบัติการจับฟ้องศาล ฐานลักนาฬิกาคุณหญิงฉัตรชฎา ฌานสมาธิ􀀀
􌿽Pijamalı hasta yağız şoföre çabucak güvendi􀀀
􌿽Жебракують філософи при ґанку церкви в Гадячі, ще й шатро їхнє п’яне знаємо􀀀
􌿽Do bạch kim rất quý nên sẽ dùng để lắp vô xương􀀀
􌿽日堀油告観観藤村抄海評業庁経賃室弁市。太撮収改売週法所何都慣次現。価紙一無三洋日話転手治稿載末替付致治。􀀀
􏃯Features:􀀀
􏿿Ever heard of « Guillemets »? You speak „Nederlands” or „Deutsch“? ”suomi”? 「日本語」しゃべる?或《中文》?􀀀
􎳌Multilingual brackets; these are the most basic things, right?􀀀
􏋶99406 91902 59186 29182 45814 57862 34368 08240􀀀
􏋶31485 65379 04348 28952 42927 26157 42615 39526􀀀
􎳌Fixed-width numbers, because number-crunching matters􀀀
􏼀ᚱ􏼐ᛂ􏼠ᚴ􏼰ᛋ􏽀ᛂ􏽐ᛋ􏽠ᛏ􏽰ᛋ􏾀ᚮ􏾐ᚾ􏾠ᛔ􏾰ᚢ􏿀ᛏ􏿐ᛚ􏿠ᚮ􏿰ᛋ􏻰᛬􏷰ᚱ􏳰ᛂ􏯰ᚴ􏫰ᛋ􏧰ᛋ􏣰ᚢ􏟰ᚼ􏛰ᚾ􏗰ᚢ􏓰ᛘ􏏰ᚢ􏋰ᛚ􏇰ᚾ􏃰ᛏ􏃱ᚮ􏃲᛬􏃳ᛏ􏃴ᚮ􏃵ᛋ􏃶ᛁ􏃷ᚮ􏃸ᚵ􏃹ᛂ􏃺ᚢ􏃻ᛏ􏃼ᚮ􏃽ᚱ􏃾ᛘ􏃿ᛔ􏃯ᚱ􏃟ᛂ􏃏ᚴ􏂿ᛋ􏂯ᛏ􏂟᛭􏂏ᛋ􏁿ᚢ􏁯ᚼ􏁟ᚾ􏁏ᚢ􏀿ᛋ􏀯ᛘ􏀟ᚮ􏀏ᛁ􏄏ᚵ􏈏ᚾ􏌏ᛁ􏐏ᛂ􏔏ᛏ􏘏ᚮ􏜏ᛑ􏠏᛭􏤏ᚵ􏨏ᛂ􏬏ᚢ􏰏ᛏ􏴏ᚮ􏸏ᚱ􀀀
􎳌Colour-code that supports 65535 opaque or semi-transparent colours via 4 bit ARGB􀀀
􏿿󿿹Гномът Доцьо приключи спящ в шейна за жаби󿿸 (Bulgarian)􀀀
􏿿󿿺Љубазни фењерџија чађавог лица хоће да ми покаже штос󿿸 (Serbian)􀀀
􏿿Разъяренный чтец эгоистично бьёт пятью жердями шустрого фехтовальщика (Russian)􀀀
􎳌Control characters to support Bulgarian and Serbian letter shapes on the fly􀀀
􏿿Press  to pay respects—or is it , or …􀀀
􎳌Custom symbols for video games􀀀
􏿿Can you distinguish following dashes: - — - - ――――――――――― 4863 48-63􀀀
􎳌For all those dash-pedants, we have en-dash, em-dash, and even horizontal bars!􀀀
􏃯Unicode References:􀀀
Basic Latin Latin-1 Latin Extension A Latin Extionsion B IPA Extension Greek Cyrillic Cyrillic Supplement
Armenian Thai Georgian Runic Cherokee General Punctuations CJK Symbols Kana
CJK Unihan Extension A CJK Unihan Hangul Syllables Fullwidth Forms
GitHubs issue page is open! You can report any 􏽕errors􀀀, or leave 􏽕suggestions􀀀.
You can help this font to be more versatile. (for more languages, more frameworks) 􏽕Clone􀀀 this repo, make changes,
and make a 􏽕pull request􀀀! I appreciate any and all supports.

View File

@@ -1,11 +1,10 @@
import com.badlogic.gdx.Game
import com.badlogic.gdx.Gdx
import com.badlogic.gdx.Screen
import com.badlogic.gdx.*
import com.badlogic.gdx.backends.lwjgl.LwjglApplication
import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration
import com.badlogic.gdx.graphics.Color
import com.badlogic.gdx.graphics.GL20
import com.badlogic.gdx.graphics.*
import com.badlogic.gdx.graphics.g2d.SpriteBatch
import com.badlogic.gdx.graphics.glutils.FrameBuffer
import com.badlogic.gdx.utils.ScreenUtils
import net.torvald.terrarumsansbitmap.gdx.GameFontBase
/**
@@ -19,11 +18,19 @@ class FontTestGDX : Game() {
lateinit var batch: SpriteBatch
override fun create() {
font = GameFontBase("./assets", flipY = false) // must test for two cases
lateinit var frameBuffer: FrameBuffer
val inTextFile = Gdx.files.internal("./FontTestGDX/demotext.txt")
val reader = inTextFile.reader()
lateinit var camera: OrthographicCamera
private val demotextName = "demotext.txt"
private val outimageName = "demo.png"
override fun create() {
font = GameFontBase("./assets", flipY = false, errorOnUnknownChar = false) // must test for two flipY cases
val inTextFile = Gdx.files.internal("./$demotextName")
val reader = inTextFile.reader("UTF-8")
inputText = reader.readLines()
reader.close()
@@ -32,133 +39,77 @@ class FontTestGDX : Game() {
println("START")
println(font.charsetOverrideDefault)
println(font.charsetOverrideBulgarian)
println(font.charsetOverrideSerbian)
val l = intArrayOf(0xFF00,
0xFF10,
0xFF20,
0xFF30,
0xFF40,
0xFF50,
0xFF60,
0xFF70,
0xFF80,
0xFF90,
0xFFA0,
0xFFB0,
0xFFC0,
0xFFD0,
0xFFE0,
0xFFF0,
0xFEF0,
0xFDF0,
0xFCF0,
0xFBF0,
0xFAF0,
0xF9F0,
0xF8F0,
0xF7F0,
0xF6F0,
0xF5F0,
0xF4F0,
0xF3F0,
0xF2F0,
0xF1F0,
0xF0F0,
0xF0F1,
0xF0F2,
0xF0F3,
0xF0F4,
0xF0F5,
0xF0F6,
0xF0F7,
0xF0F8,
0xF0F9,
0xF0FA,
0xF0FB,
0xF0FC,
0xF0FD,
0xF0FE,
0xF0FF,
0xF0EF,
0xF0DF,
0xF0CF,
0xF0BF,
0xF0AF,
0xF09F,
0xF08F,
0xF07F,
0xF06F,
0xF05F,
0xF04F,
0xF03F,
0xF02F,
0xF01F,
0xF00F,
0xF10F,
0xF20F,
0xF30F,
0xF40F,
0xF50F,
0xF60F,
0xF70F,
0xF80F,
0xF90F,
0xFA0F,
0xFB0F,
0xFC0F,
0xFD0F,
0xFE0F,
0xFF0F)
val s = "ᚱᛂᚴᛋᛂᛋᛏᛋᚮᚾᛔᚢᛏᛚᚮᛋ᛬ᚱᛂᚴᛋᛋᚢᚼᚾᚢᛘᚢᛚᚾᛏᚮ᛬ᛏᚮᛋᛁᚮᚵᛂᚢᛏᚮᚱᛘᛔᚱᛂᚴᛋᛏ᛭ᛋᚢᚼᚾᚢᛋᛘᚮᛁᚵᚾᛁᛂᛏᚮᛑ᛭ᚵᛂᚢᛏᚮᚱ"
var lc = 0
var sc = 0
frameBuffer = FrameBuffer(Pixmap.Format.RGBA8888, TEXW, TEXH, true)
while (lc < l.size) {
print(font.toColorCode(l[lc]))
print(s[sc])
camera = OrthographicCamera(TEXW.toFloat(), TEXH.toFloat())
camera.translate(TEXW.div(2f), 0f)
camera.setToOrtho(true, TEXW.toFloat(), TEXH.toFloat())
camera.update()
lc++
sc++
if (sc == s.length) break
if (s[sc] == ' ') {
print(" ")
sc++
}
}
println("${font.noColorCode}\nEND")
println(font.toColorCode(0xC_FFD))
println(font.toColorCode(0xF_F55))
println(font.toColorCode(0xE_CCC))
Gdx.input.inputProcessor = Navigator(this)
}
override fun getScreen(): Screen? {
return null
}
var scrollOffsetY = 0f
override fun setScreen(screen: Screen?) {
}
var tex: Texture? = null
var screenshotExported = false
override fun render() {
Gdx.gl.glClearColor(.141f, .141f, .141f, 1f)
Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT)
Gdx.gl.glEnable(GL20.GL_TEXTURE_2D)
Gdx.gl.glEnable(GL20.GL_BLEND)
Gdx.gl.glBlendFunc(GL20.GL_SRC_ALPHA, GL20.GL_ONE_MINUS_SRC_ALPHA)
if (tex == null) {
frameBuffer.begin()
Gdx.gl.glClearColor(.141f, .141f, .141f, 1f)
Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT)
Gdx.gl.glEnable(GL20.GL_TEXTURE_2D)
Gdx.gl.glEnable(GL20.GL_BLEND)
Gdx.gl.glBlendFunc(GL20.GL_SRC_ALPHA, GL20.GL_ONE_MINUS_SRC_ALPHA)
batch.projectionMatrix = camera.combined
batch.begin()
batch.color = Color(0xeeeeeeff.toInt())
inputText.forEachIndexed { index, s ->
font.draw(batch, s, 10f, TEXH - 30f - index * font.lineHeight)
}
batch.end()
// dump to file
if (!screenshotExported) {
val pixmap = ScreenUtils.getFrameBufferPixmap(0, 0, frameBuffer.width, frameBuffer.height)
PixmapIO.writePNG(Gdx.files.local(outimageName), pixmap)
pixmap.dispose()
screenshotExported = true
}
frameBuffer.end()
///////////////
tex = frameBuffer.colorBufferTexture
}
batch.begin()
batch.color = Color.WHITE
batch.draw(tex, 0f, (TEXH.toFloat()/appConfig.height)*TEXH - scrollOffsetY, TEXW.toFloat(), -(TEXH.toFloat() / appConfig.height) * TEXH.toFloat())
batch.color = Color(0xeeeeeeff.toInt())
inputText.forEachIndexed { index, s ->
font.draw(batch, s, 10f, appConfig.height - 30f - index * font.lineHeight)
}
batch.end()
}
@@ -175,16 +126,46 @@ class FontTestGDX : Game() {
override fun dispose() {
font.dispose()
}
fun scrollAdd(x: Int = 1) {
scrollOffsetY -= (TEXH.toFloat() / appConfig.height) * 20f * x
}
fun scrollSub(x: Int = 1) {
scrollOffsetY += (TEXH.toFloat() / appConfig.height) * 20f * x
}
class Navigator(val main: FontTestGDX) : InputAdapter() {
override fun scrolled(amount: Int): Boolean {
if (amount >= 0)
main.scrollSub(amount)
else
main.scrollAdd(-amount)
return true
}
override fun keyDown(keycode: Int): Boolean {
if (keycode == Input.Keys.UP)
main.scrollAdd()
else if (keycode == Input.Keys.DOWN)
main.scrollSub()
return true
}
}
}
lateinit var appConfig: LwjglApplicationConfiguration
const val TEXW = 874
const val TEXH = 2400
fun main(args: Array<String>) {
appConfig = LwjglApplicationConfiguration()
appConfig.vSyncEnabled = false
appConfig.resizable = false//true;
appConfig.width = 960
appConfig.height = 2048
appConfig.width = TEXW
appConfig.height = 768
appConfig.title = "Terrarum Sans Bitmap Test (GDX)"
LwjglApplication(FontTestGDX(), appConfig)

View File

@@ -1,6 +1,6 @@
Terrarum Sans Bitmap
Copyright (c) 2017-2018 Minjae Song (Torvald) and the contributors
Copyright (c) 2017-2019 Minjae Song (Torvald) and the contributors
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

Binary file not shown.

135
README.md
View File

@@ -2,15 +2,17 @@
![Font sample](demo.PNG)
This font is a bitmap font used in [my game project called Terrarum](https://gitlab.com/minjaesong/terrarum) (hence the name). The font supports more than 90 % of european languages, as well as Chinese, Japanese and Korean. More technical side, it supports Latin-1 Supplement, Latin Ext-A, Latin Ext-B, IPA Extension (required by some languages), Greek, Cyrillic (+ Bulgarian, Serbian variants) and the supplement, Armenian, Thai (beta version), Georgian, Unicode Punctuations, CJK Punctuations, Kana, Chinese (limited to Unihan and Ext-A), Hangul (all 11 172 possible syllables) and Fullwidth forms.
This font is a bitmap font used in [my game project called Terrarum](https://github.com/minjaesong/Terrarum) (hence the name). The font supports more than 90 % of european languages, as well as Chinese, Japanese and Korean. More technical side, it supports Latin-1 Supplement, Latin Ext-A, Latin Ext-B, IPA Extension (required by some languages), Greek, Cyrillic (+ Bulgarian, Serbian variants) and the supplement, Armenian, Thai (beta version), Georgian, Unicode Punctuations, CJK Punctuations, Kana, Chinese (limited to Unihan and Ext-A), Hangul (all 11 172 possible syllables) and Fullwidth forms.
The JAR package is meant to be used with Slick2d (extends ```Font``` class) and LibGDX (extends ```BitmapFont``` class). If you are not using the framework, please refer to the __Font metrics__ section to implement the font metrics correctly on your system.
The JAR package is meant to be used with LibGDX (extends ```BitmapFont``` class). If you are not using the framework, please refer to the __Font metrics__ section to implement the font metrics correctly on your system.
The issue page is open. If you have some issues to submit, or have a question, please leave it on the page.
#### Little notes
- You can't display Bulgarian, Russian and Serbian variants at the same time without some more codes; ```reload()```ing them or creating multiple instances of the font would be the easiest solutions.
- To display Bulgarian/Serbian variants, you need special Control Characters. (GameFontBase.charsetOverrideBulgarian -- U+FFFC1; GameFontBase.charsetOverrideSerbian -- U+FFFC2)
- All Han characters are in Chinese variant, no other variants are to be supported as most Chinese, Japanese and Korean can understand other's variant and to be honest, we don't bother anyway.
- Indian script in general is not perfect: this font will never do the proper ligatures (I can't draw all the 1 224 possible combinations). Hopefully it's still be able to understand without them.
- Slick2d versions are now unsupported. I couldn't extend myself to work on both versions, but I'm still welcome to merge your pull requests.
### Design Goals
@@ -19,10 +21,13 @@ The issue page is open. If you have some issues to submit, or have a question, p
- Combininig with the sans-serif, this stands for **no over-simplification**
- Condensed capitals for efficient space usage
## Download
- Go ahead to the [release tab](https://github.com/minjaesong/Terrarum-sans-bitmap/releases), and download the most recent version. It is **not** advised to use the .jar found within the repository, they're experimental builds I use during the development, and may contain bugs like leaking memory.
## Using on your game
- Firstly, place the .jar to your library path and unzip spritesheets, then:
- Firstly, place the .jar to your library path and assets folder to the main directory of the app, then:
### Using on LibGDX
@@ -107,133 +112,19 @@ On your code (Java):
Color codes are individual unicode characters. While you can somehow make a raw character and paste in on your code, it's certainly not desirable. Fortunately, we're also providing utility functions for the color codes.
GameFontBase.toColorCode(rgba4444: Int) -- returns String
GameFontBase.toColorCode(argb4444: Int) -- returns String
GameFontBase.toColorCode(r: Int, g: Int, b: Int) -- returns String
GameFontBase.toColorCode(r: Int, g: Int, b: Int, a: Int) -- returns String
```rgba4444``` takes whole RGBA as input, that is, from 0x0000 to 0xFFFF. Most significant bits represents Red, and least significant bits represents Alpha (which should be fixed as F for the most time)
```argb4444``` takes whole ARGB (in that order) as input, that is, from 0x0000 to 0xFFFF.
```r, g, b(, a)``` takes RGB and A separately, in the range of 0x0..0xF. Any value exceeding the range **are unchecked and may wreak havoc**, so be careful.
U+100000 is used to disable previously-applied color codes (going back to original colour), although it may seem like RGBA of all zero.
U+100000 is used to disable previously-applied color codes (going back to original colour), even if it looks like ARGB of all zero.
## Contribution guidelines
You can contribute to the font by fixing wrong glyphs, suggesting better ones, extending character set (letters for other writing systems or filling in the blanks on the existing ones), or code for other game frameworks (not limited to Java). Please leave pull request for that.
Font Spritesheets are stored in ```assets/graphics/fonts``` directory. Image format must be TGA with Alpha — no PNG. If someone needs PNG, they can batch-convert the font using utils like ImageMagick.
### Ascenders, descenders, width informations
![Alas, use more modern browser or get better internet connexion!](glyph_height_pos_annotation.png)
Above image is a reference you can use while you draw some letters. Capital B is drawn as a reference. Orange-tinted area is for lowercase, x-height must be the same as that of said tinted area (lowercase Alpha is also drawn for the reference). NOTE THAT x-height is taller than centre bar (capital A is an exception). Height of the ascender of the lowercase letters must be the same as height of capital letters.
Red-tinted area SHOULD NOT CONTAIN any dots, it's emptied for compatibility. (Slick2d—you can define size of "gaps" of the spritesheet, but you can't define horizontal and vertical gap separately)
Blue-tinted area cotains width of the glyph in binary, uppermost dot is the Least Significant Bit.
Green-tinted area contains extra informations, left blank for most cases. (will be expanded later; no standard has been issued yet)
Tinted-in-magenta shows the height where diacritics should be placed, for both uppercase and lowercase.
Each cell is 16 px wide, and any glyph you draw **must be contained within leftside FIFTEEN pixels**.
### Font metrics
Although the font is basically a Spritesheet, some of the sheet expects variable widths to be supported. Any sheets with ```_variable``` means it expects variable widths. Anything else expects fixed width (regular Spritesheet behaviour). ```cjkpunct``` has width of 10, ```kana``` and ```hangul_johab``` has width of 12, ```wenquanyi``` has width of 16.
### Parsing glyph widths for variable font sheets
![Sample of Font Spritesheet with annotation](width_bit_encoding_annotated.png)
Width is encoded in binary bits, on pixels. On the font spritesheet, every glyph has vertical dots on their top-right side (to be exact, every (16k - 1)th pixel on x axis). Above image is a sample of the font, with width information coloured in magenta. From top to bottom, each dot represents 1, 2, 4 and 8. For example, in the above image, ! (exclamation mark) has width of 5, " (double quote) has width of 6, # (octothorp) has width of 8, $ (dollar sign) has width of 9.
### Implementing the Korean writing system
On this font, Hangul letters are printed by assemblying two or three letter pieces. There are 10 sets of Hangul letter pieces on the font. Top 6 are initials, middle 2 are medials, and bottom 2 are finals. On the rightmost side, there's eight assembled glyphs to help you with (assuming you have basic knowledge on the writing system). Top 6 tells you how to use 6 initials, and bottom 2 tells you how to use 2 finals.
This is a Kotlin-like pseudocode for assembling the glyph:
function getHanChosung(hanIndex: Int) = hanIndex / (21 * 28)
function getHanJungseong(hanIndex: Int) = hanIndex / 28 % 21
function getHanJongseong(hanIndex: Int) = hanIndex % 28
jungseongWide = arrayOf(8, 12, 13, 17, 18, 21)
jungseongComplex = arrayOf(9, 10, 11, 14, 15, 16, 22)
function getHanInitialRow(hanIndex: Int): Int {
val ret: Int
if (isJungseongWide(hanIndex))
ret = 2
else if (isJungseongComplex(hanIndex))
ret = 4
else
ret = 0
return if (getHanJongseong(hanIndex) == 0) ret else ret + 1
}
function isJungseongWide(hanIndex: Int) = jungseongWide.contains(getHanJungseong(hanIndex))
function isJungseongComplex(hanIndex: Int) = jungseongComplex.contains(getHanJungseong(hanIndex))
function getHanInitialRow(hanIndex: Int): Int {
val ret: Int
if (isJungseongWide(hanIndex))
ret = 2
else if (isJungseongComplex(hanIndex))
ret = 4
else
ret = 0
return if (getHanJongseong(hanIndex) == 0) ret else ret + 1
}
function getHanMedialRow(hanIndex: Int) = if (getHanJongseong(hanIndex) == 0) 6 else 7
function getHanFinalRow(hanIndex: Int): Int {
val jungseongIndex = getHanJungseong(hanIndex)
return if (jungseongWide.contains(jungseongIndex))
8
else
9
}
function isHangul(c: Char) = c.toInt() >= 0xAC00 && c.toInt() < 0xD7A4
...
for (each Char on the string) {
if (isHangul(Char)) {
val hIndex = Char.toInt() - 0xAC00
val indexCho = getHanChosung(hIndex)
val indexJung = getHanJungseong(hIndex)
val indexJong = getHanJongseong(hIndex)
val choRow = getHanInitialRow(hIndex)
val jungRow = getHanMedialRow(hIndex)
val jongRow = getHanFinalRow(hIndex)
// get sub image from sprite sheet
val choseongImage = hangulSheet.getSubImage(indexCho, choRow)
val jungseongImage = hangulSheet.getSubImage(indexJung, jungRow)
val jongseongImage = hangulSheet.getSubImage(indexJong, jongRow)
// actual drawing part
draw choseongImage to somewhere you want
draw jungseongImage on top of choseongImage
draw jongseongImage on top of choseongImage
}
...
}
Please refer to [CONTRIBUTING.md](https://github.com/minjaesong/Terrarum-sans-bitmap/blob/master/CONTRIBUTING.md)
## Acknowledgement

BIN
alignment_illustration.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 59 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 160 KiB

After

Width:  |  Height:  |  Size: 160 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 260 KiB

After

Width:  |  Height:  |  Size: 260 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 320 KiB

After

Width:  |  Height:  |  Size: 320 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 380 KiB

After

Width:  |  Height:  |  Size: 380 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 320 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 140 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 320 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 262 KiB

After

Width:  |  Height:  |  Size: 1.3 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 220 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 180 KiB

After

Width:  |  Height:  |  Size: 210 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 60 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 320 KiB

After

Width:  |  Height:  |  Size: 320 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 120 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 120 KiB

After

Width:  |  Height:  |  Size: 200 KiB

BIN
demo.PNG

Binary file not shown.

Before

Width:  |  Height:  |  Size: 129 KiB

After

Width:  |  Height:  |  Size: 145 KiB

118
demotext.txt Normal file
View File

@@ -0,0 +1,118 @@
􏿆The bitmap font for games developers who seek good font that has real multilingual support,􀀀
􏿆for free (as in freedom and without cost)􀀀
There are many bitmap fonts on the internet. You care for the multilingual support, but alas!
most of them do not support your language, vector fonts take too much time to load, and even
then their legibility suffers because fuck built-in antialias.
You somehow found a multilingual one, and it makes your game look like an old computer, and you say:
“Well, better than nothing… no, its ugly.”
You speak japanese and you wish to support it, but then このクソなfont only goot for displaying
Japanese, its not even multilingual, and their English look uncanny and inconsistent as hell.
Eventually you just mix different fonts together, and the results were always infuriating.
No more suffering. This font has everything you need.
􏾐while􀀀 (isVisible(􏺟BAD_FONTS􀀀)) {
ripAndTear(􏺟BAD_FONTS􀀀).where { 􏺟GUTS􀀀 };
}
How multilingual? Real multilingual!
􏻬Ианҵоуп ақьаад, нусхур аҩырала, ҩ ҽшьаҟакла, иҧшӡоу анапҩырала􀀀
􏻬գրիչս վայր դրի, վեր կացա և պատրաստվում էի, որ քնեմ, երբ հանկարծ դռանս զանգակը հնչեց􀀀
􏻬ՄՇԱԿԻՉ ԿԱՄ ԿԵՆՏՐՈՆԱԿԱՆ ՄՇԱԿԻՉ ՀԱՆԳՈՒՅՑԸ ՀԱՆԴԻՍԱՆՈՒՄ Է ՀԱՄԱԿԱՐԳՉԻ ՍԱՐՔԱՎՈՐՈՒՄՆԵՐԻՑ􀀀
􏻬Zəfər, jaketini də papağını da götür, bu axşam hava çox soyuq olacaq􀀀
􏻬আমি কাঁচ খেতে পারি, তাতে আমার কোনো ক্ষতি হয় না। 􀀀
􏻬󿿁Под южно дърво, цъфтящо в синьо, бягаше малко пухкаво зайче󿿀􀀀
􏻬ᎠᏍᎦᏯᎡᎦᎢᎾᎨᎢᎣᏍᏓᎤᎩᏍᏗᎥᎴᏓᎯᎲᎢᏔᎵᏕᎦᏟᏗᏖᎸᎳᏗᏗᎧᎵᎢᏘᎴᎩ ᏙᏱᏗᏜᏫᏗᏣᏚᎦᏫᏛᏄᏓᎦᏝᏃᎠᎾᏗᎭᏞᎦᎯᎦᏘᏓᏠᎨᏏᏕᏡᎬᏢᏓᏥᏩᏝᎡᎢᎪᎢ􀀀
􏻬ᎠᎦᏂᏗᎮᎢᎫᎩᎬᏩᎴᎢᎠᏆᏅᏛᎫᏊᎾᎥᎠᏁᏙᎲᏐᏈᎵᎤᎩᎸᏓᏭᎷᏤᎢᏏᏉᏯᏌᏊ ᎤᏂᏋᎢᏡᎬᎢᎰᏩᎬᏤᎵᏍᏗᏱᎩᎱᎱᎤᎩᎴᎢᏦᎢᎠᏂᏧᏣᏨᎦᏥᎪᎥᏌᏊᎤᎶᏒᎢᎢᏡᎬᎢ􀀀
􏻬ᎹᎦᎺᎵᏥᎻᎼᏏᎽᏗᏩᏂᎦᏘᎾᎿᎠᏁᎬᎢᏅᎩᎾᏂᎡᎢᏌᎶᎵᏎᎷᎠᏑᏍᏗᏪᎩ ᎠᎴ ᏬᏗᏲᏭᎾᏓᏍᏓᏴᏁᎢᎤᎦᏅᏮᏰᎵᏳᏂᎨᎢ􀀀
􏻬Příliš žluťoučký kůň úpěl ďábelské ódy􀀀
􏻬Quizdeltagerne spiste jordbær med fløde, mens cirkusklovnen Walther spillede på xylofon􀀀
􏻬PACK MY BOX WITH FIVE DOZEN LIQUOR JUGS􀀀
􏻬hƿæt ƿe ᵹardena inᵹear ꝺaᵹum þeoꝺ cynninᵹa þꞃym ᵹeꝼꞃumon􀀀
􏻬Victor jagt zwölf Boxkämpfer quer über den großen Sylter Deich GROẞEN GROẞE􀀀
􏻬ζαφείρι δέξου πάγκαλο, βαθῶν ψυχῆς τὸ σῆμα􀀀
􏻬ΔΙΑΦΥΛΆΞΤΕ ΓΕΝΙΚΆ ΤΗ ΖΩΉ ΣΑΣ ΑΠΌ ΒΑΘΕΙΆ ΨΥΧΙΚΆ ΤΡΑΎΜΑΤΑ􀀀
􏻬სწრაფი ყავისფერი მელა გადაახტა ზარმაც ძაღლს ᲘᲜᲢᲔᲚ ᲞᲔᲜᲢᲘᲣᲛᲘ ᲛᲘᲙᲠᲝᲞᲠᲝᲪᲔᲡᲝᲠᲘ􀀀
􏻬ऋषियों को सताने वाले दुष्ट राक्षसों के राजा रावण का सर्वनाश करने वाले विष्णुवतार भगवान श्रीराम अयोध्या के महाराज दशरथ के􀀀
􏻬Kæmi ný öxi hér, ykist þjófum nú bæði víl og ádrepa􀀀
􏻬Ċuaiġ bé ṁórṡáċ le dlúṫspád fíorḟinn trí hata mo ḋea-ṗorcáin ḃig􀀀
􏻬あめつちほしそら やまかはみねたに くもきりむろこけ ひといぬうへすゑ ゆわさるおふせよ えの𛀁をなれゐて􀀀
􏻬トリナクコヱス ユメサマセ ミヨアケワタル ヒンカシヲ ソライロハエテ オキツヘニ ホフネムレヰヌ モヤノウチ􀀀
􏻬田居に出で 菜摘むわれをぞ 君召すと 求食り追ひゆく 山城の 打酔へる子ら 藻葉干せよ え舟繋けぬ􀀀
􏻬정 참판 양반댁 규수 큰 교자 타고 혼례 치른 날 하얬다 도럄직한 퀡봹퉪헰ꥸᅦퟗꥸᅦퟗᄋힳᆫ􀀀
􏻬Četri psihi faķīri vēlu vakarā zāģēja guļbūvei durvis, fonā šņācot mežam􀀀
􏻬Įlinkdama fechtuotojo špaga sublykčiojusi pragręžė apvalų arbūzą􀀀
􏻬Ѕидарски пејзаж: шугав билмез со чудење џвака ќофте и кељ на туѓ цех􀀀
􏻬Щётканы фермд пийшин цувъя. Бөгж зогсч хэльюү􀀀
􏻬Pchnąć w tę łódź jeża lub ośm skrzyń fig􀀀
􏻬कः खगौघाङचिच्छौजा झाञ्ज्ञोऽटौठीडडण्ढणः। तथोदधीन् पफर्बाभीर्मयोऽरिल्वाशिषां सहः॥􀀀
􏻬Înjurând pițigăiat, zoofobul comandă vexat whisky și tequila􀀀
􏻬Широкая электрификация южных губерний даст мощный толчок подъёму сельского хозяйства􀀀
􏻬󿿂Ајшо, лепото и чежњо, за љубав срца мога дођи у Хаџиће на кафу󿿀􀀀
􏻬Jovencillo emponzoñado de whisky: ¡qué figurota exhibe!􀀀
􏻬นายสังฆภัณฑ์ เฮงพิทักษ์ฝั่ง ผู้เฒ่าซึ่งมีอาชีพเป็นฅนขายฃวด ถูกตำรวจปฏิบัติการจับฟ้องศาล ฐานลักนาฬิกาคุณหญิงฉัตรชฎา ฌานสมาธิ􀀀
􏻬Pijamalı hasta yağız şoföre çabucak güvendi􀀀
􏻬Жебракують філософи при ґанку церкви в Гадячі, ще й шатро їхнє п’яне знаємо􀀀
􏻬Do bạch kim rất quý nên sẽ dùng để lắp vô xương􀀀
􏻬日堀油告観観藤村抄海評業庁経賃室弁市。太撮収改売週法所何都慣次現。価紙一無三洋日話転手治稿載末替付致治。􀀀
􏻬[pʰnɣɬɥi.m͡ŋχɫʍɨnaɸ.cθʊɫɯ.ɹɨɫʏ͡ɛx.ɯ͡ɣaxɲaɣɫ.ɸtʰɑɣɴ]􀀀
􏃯Features:􀀀
􏿿Ever heard of « Guillemets »? You speak „Nederlands” or „Deutsch“? ”suomi”? 「日本語」しゃべる?或《中文》?􀀀
􎳌Multilingual brackets; these are the most basic things, right?􀀀
􏋶99406 91902 59186 29182 45814 57862 34368 08240􀀀
􏋶31485 65379 04348 28952 42927 26157 42615 39526􀀀
􎳌Fixed-width numbers, because number-crunching matters􀀀
􏼀ᚱ􏼐ᛂ􏼠ᚴ􏼰ᛋ􏽀ᛂ􏽐ᛋ􏽠ᛏ􏽰ᛋ􏾀ᚮ􏾐ᚾ􏾠ᛔ􏾰ᚢ􏿀ᛏ􏿐ᛚ􏿠ᚮ􏿰ᛋ􏻰᛬􏷰ᚱ􏳰ᛂ􏯰ᚴ􏫰ᛋ􏧰ᛋ􏣰ᚢ􏟰ᚼ􏛰ᚾ􏗰ᚢ􏓰ᛘ􏏰ᚢ􏋰ᛚ􏇰ᚾ􏃰ᛏ􏃱ᚮ􏃲᛬􏃳ᛏ􏃴ᚮ􏃵ᛋ􏃶ᛁ􏃷ᚮ􏃸ᚵ􏃹ᛂ􏃺ᚢ􏃻ᛏ􏃼ᚮ􏃽ᚱ􏃾ᛘ􏃿ᛔ􏃯ᚱ􏃟ᛂ􏃏ᚴ􏂿ᛋ􏂯ᛏ􏂟᛭􏂏ᛋ􏁿ᚢ􏁯ᚼ􏁟ᚾ􏁏ᚢ􏀿ᛋ􏀯ᛘ􏀟ᚮ􏀏ᛁ􏄏ᚵ􏈏ᚾ􏌏ᛁ􏐏ᛂ􏔏ᛏ􏘏ᚮ􏜏ᛑ􏠏᛭􏤏ᚵ􏨏ᛂ􏬏ᚢ􏰏ᛏ􏴏ᚮ􏸏ᚱ􀀀
􎳌Colour-code that supports 4096 colours via 4 bit RGB􀀀
􏿿󿿁Щиглецът се яде само пържен в юфка без чушки и хвойна󿿀 (Bulgarian)􀀀
􏿿󿿂Љубазни фењерџија чађавог лица хоће да ми покаже штос󿿀 (Serbian)􀀀
􏿿Разъяренный чтец эгоистично бьёт пятью жердями шустрого фехтовальщика (Russian)􀀀
􎳌Control characters to support Bulgarian and Serbian letter shapes on the fly􀀀
􏿿Press  to pay respects—or is it , or …􀀀
􎳌Custom symbols for video games􀀀
􏿿Can you distinguish following dashes: - — - - ――――――――――― 4863 48-63􀀀
􎳌For all those dash-pedants, we have en-dash, em-dash, and even horizontal bars!􀀀
􏿿5¹⁹₃₂ inch is 142.1 mm · (C₂F₄)ₙ is godly · Error = MoreCode²􀀀
􏿿NOTE: we dont do fractions. 142¹₁₀ mm is illegal!􀀀
􎳌Did you know Unicode supports arbitrary fractions? Actually I didnt… as they abused super/subscripts!􀀀
􏿿ᄋᆡ급 일 ᄭᅡᄃᆞᆰ에 영국 ᄒᆞ고 불난셔 ᄒᆞ고 ᄃᆡ단이 시비가 잇슬 모양 인ᄃᆡ􀀀
􏿿일본 농샹공부에셔 젼긔학 학ᄉᆞ 셋ᄉᆞᆯ 미국과 구라파로 보내셔 젼화 쓰ᄂᆞᆫ 법을 더ᄇᆡ호게 ᄒᆞ더라􀀀
􏿿일쳔 구ᄇᆡᆨ년에 불난셔 셔울 파리스에 만국 박남회를 버릴터 인ᄃᆡ 각국이 다 물화와 졔조품을 거긔 보낼터이더라􀀀
􎳌Rejoice, now we can render Old Korean in a correct way!􀀀
􏃯Unicode References:􀀀
Basic Latin Latin-1 Supplement Latin Extended-A Latin Extended-B IPA Extension Greek Cyrillic
Cyrillic Supplement Armenian Devanagari Bengali Thai Georgian Hangul Jamo Cherokee Runic
Georgian Extended Greek Extended General Punctuations Superscripts and Subscripts CJK Symbols
Latin Extended-C Kana Kana Phonetic Extension CJK Unihan Extension A CJK Unihan
Hangul Jamo Extended-A Hangul Syllables Hangul Jamo Extended-B Fullwidth Forms Kana Supplement
GitHubs issue page is open! You can report any 􏽕errors􀀀, or leave 􏽕suggestions􀀀.
You can help this font to be more versatile. (for more languages, more frameworks) 􏽕Clone􀀀 this repo, make
changes, and make a 􏽕pull request􀀀! I appreciate any and all supports.
<EFBFBD> 􎳌文字化け!􀀀 <20>

BIN
font_drawing_template.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

View File

@@ -0,0 +1,66 @@
package net.torvald.terrarumsansbitmap
/**
* Created by minjaesong on 2018-08-07.
*/
data class GlyphProps(
val width: Int,
val writeOnTop: Boolean,
val alignWhere: Int,
val alignXPos: Int,
val rtl: Boolean = false,
val stackWhere: Int = 0,
var extInfo: IntArray? = null
) {
companion object {
const val ALIGN_LEFT = 0
const val ALIGN_RIGHT = 1
const val ALIGN_CENTRE = 2
const val ALIGN_BEFORE = 3
const val STACK_UP = 0
const val STACK_DOWN = 1
const val STACK_BEFORE_N_AFTER = 2
const val STACK_UP_N_DOWN = 3
const val DIA_OVERLAY = 1
const val DIA_JOINER = 2
private fun Boolean.toInt() = if (this) 1 else 0
}
constructor(width: Int, tags: Int) : this(
width,
tags.ushr(7).and(1) == 1,
tags.ushr(5).and(3),
tags.ushr(1).and(15),
tags.and(1) == 1,
tags.ushr(8).and(3)
)
fun isOverlay() = writeOnTop && alignXPos == 1
override fun hashCode(): Int {
val tags = rtl.toInt() or alignXPos.shl(1) or alignWhere.shl(5) or
writeOnTop.toInt().shl(7) or stackWhere.shl(8)
var hash = -2128831034
extInfo?.forEach {
hash = hash xor it
hash = hash * 16777619
}
hash = hash xor tags
hash = hash * 167677619
return hash
}
override fun equals(other: Any?): Boolean {
// comparing hash because I'm lazy
return other is GlyphProps && this.hashCode() == other.hashCode()
}
fun requiredExtInfoCount() = if (stackWhere == STACK_BEFORE_N_AFTER) 2 else 0
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,167 @@
/*
* Terrarum Sans Bitmap
*
* Copyright (c) 2018 Minjae Song (Torvald)
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
package net.torvald.terrarumsansbitmap.gdx
import com.badlogic.gdx.files.FileHandle
import com.badlogic.gdx.graphics.Color
import com.badlogic.gdx.graphics.Pixmap
/**
* Created by minjaesong on 2018-09-17.
*/
class PixmapRegionPack(
pixmap: Pixmap,
val tileW: Int,
val tileH: Int,
val hGap: Int = 0,
val vGap: Int = 0,
val hFrame: Int = 0,
val vFrame: Int = 0,
val xySwapped: Boolean = false // because Unicode chart does, duh
) {
//constructor(ref: String, tileW: Int, tileH: Int, hGap: Int = 0, vGap: Int = 0, hFrame: Int = 0, vFrame: Int = 0, xySwapped: Boolean = false) :
// this(Pixmap(ref), tileW, tileH, hGap, vGap, hFrame, vFrame, xySwapped)
constructor(fileHandle: FileHandle, tileW: Int, tileH: Int, hGap: Int = 0, vGap: Int = 0, hFrame: Int = 0, vFrame: Int = 0, xySwapped: Boolean = false) :
this(Pixmap(fileHandle), tileW, tileH, hGap, vGap, hFrame, vFrame, xySwapped)
val horizontalCount = (pixmap.width - 2 * hFrame + hGap) / (tileW + hGap)
val verticalCount = (pixmap.height - 2 * vFrame + vGap) / (tileH + vGap)
val regions: Array<Pixmap>
init {
// test print the whole sheet
/*pixmap.pixels.rewind()
for (y in 0 until pixmap.height) {
for (x in 0 until pixmap.width) {
pixmap.pixels.get() // discard r
pixmap.pixels.get() // discard g
pixmap.pixels.get() // discard b
val a = pixmap.pixels.get()
if (a == 255.toByte()) print("█") else print("·")
}
println()
}
println()*/
pixmap.pixels.rewind()
if (!xySwapped) {
regions = Array<Pixmap>(horizontalCount * verticalCount, {
val rx = (it % horizontalCount * (tileW + hGap)) + hFrame // pixel, not index
val ry = (it / horizontalCount * (tileH + vGap)) + vFrame // pixel, not index
val region = Pixmap(tileW, tileH, Pixmap.Format.RGBA8888)
region.pixels.rewind()
// for every "scanline"
for (y in 0 until tileH) {
val offsetY = (ry + y) * (pixmap.width * 4) + (vFrame * pixmap.width * 4)
val offsetX = rx * 4 + hFrame * 4
//println("offset: ${offsetX + offsetY}")
val bytesBuffer = ByteArray(4 * tileW)
pixmap.pixels.position(offsetY + offsetX)
pixmap.pixels.get(bytesBuffer, 0, bytesBuffer.size)
// test print bytesbuffer
/*bytesBuffer.forEachIndexed { index, it ->
if (index % 4 == 3) {
if (it == 255.toByte()) print("█") else print("·")
}
}
println()*/
region.pixels.put(bytesBuffer)
}
//println()
// todo globalFlipY ?
/*return*/region
})
}
else {
regions = Array<Pixmap>(horizontalCount * verticalCount, {
val rx = (it / verticalCount * (tileW + hGap)) + hFrame
val ry = (it % verticalCount * (tileH + vGap)) + vFrame
val region = Pixmap(tileW, tileH, Pixmap.Format.RGBA8888)
region.pixels.rewind()
// for every "scanline"
for (y in 0 until tileH) {
val offsetY = (ry + y) * (pixmap.width * 4) + (vFrame * pixmap.width * 4)
val offsetX = rx * 4 + hFrame * 4
//println("offset: ${offsetX + offsetY}")
val bytesBuffer = ByteArray(4 * tileW)
pixmap.pixels.position(offsetY + offsetX)
pixmap.pixels.get(bytesBuffer, 0, bytesBuffer.size)
// test print bytesbuffer
/*bytesBuffer.forEachIndexed { index, it ->
if (index % 4 == 3) {
if (it == 255.toByte()) print("█") else print("·")
}
}
println()*/
region.pixels.put(bytesBuffer)
}
//println()
// todo globalFlipY ?
/*return*/region
})
}
}
fun get(x: Int, y: Int) = regions[y * horizontalCount + x]
fun dispose() {
regions.forEach { it.dispose() }
}
}

View File

@@ -38,13 +38,14 @@ class TextureRegionPack(
val hGap: Int = 0,
val vGap: Int = 0,
val hFrame: Int = 0,
val vFrame: Int = 0
val vFrame: Int = 0,
val xySwapped: Boolean = false // because Unicode chart does, duh
) {
constructor(ref: String, tileW: Int, tileH: Int, hGap: Int = 0, vGap: Int = 0, hFrame: Int = 0, vFrame: Int = 0) :
this(Texture(ref), tileW, tileH, hGap, vGap, hFrame, vFrame)
constructor(fileHandle: FileHandle, tileW: Int, tileH: Int, hGap: Int = 0, vGap: Int = 0, hFrame: Int = 0, vFrame: Int = 0) :
this(Texture(fileHandle), tileW, tileH, hGap, vGap, hFrame, vFrame)
constructor(ref: String, tileW: Int, tileH: Int, hGap: Int = 0, vGap: Int = 0, hFrame: Int = 0, vFrame: Int = 0, xySwapped: Boolean = false) :
this(Texture(ref), tileW, tileH, hGap, vGap, hFrame, vFrame, xySwapped)
constructor(fileHandle: FileHandle, tileW: Int, tileH: Int, hGap: Int = 0, vGap: Int = 0, hFrame: Int = 0, vFrame: Int = 0, xySwapped: Boolean = false) :
this(Texture(fileHandle), tileW, tileH, hGap, vGap, hFrame, vFrame, xySwapped)
companion object {
/** Intented for Y-down coord system, typically fon Non-GDX codebase */
@@ -59,18 +60,34 @@ class TextureRegionPack(
init {
//println("texture: $texture, dim: ${texture.width} x ${texture.height}, grid: $horizontalCount x $verticalCount, cellDim: $tileW x $tileH")
regions = Array<TextureRegion>(horizontalCount * verticalCount, {
val region = TextureRegion()
val rx = (it % horizontalCount * (tileW + hGap)) + hFrame
val ry = (it / horizontalCount * (tileH + vGap)) + vFrame
if (!xySwapped) {
regions = Array<TextureRegion>(horizontalCount * verticalCount, {
val region = TextureRegion()
val rx = (it % horizontalCount * (tileW + hGap)) + hFrame
val ry = (it / horizontalCount * (tileH + vGap)) + vFrame
region.setRegion(texture)
region.setRegion(rx, ry, tileW, tileH)
region.setRegion(texture)
region.setRegion(rx, ry, tileW, tileH)
region.flip(false, globalFlipY)
region.flip(false, globalFlipY)
/*return*/region
})
/*return*/region
})
}
else {
regions = Array<TextureRegion>(horizontalCount * verticalCount, {
val region = TextureRegion()
val rx = (it / verticalCount * (tileW + hGap)) + hFrame
val ry = (it % verticalCount * (tileH + vGap)) + vFrame
region.setRegion(texture)
region.setRegion(rx, ry, tileW, tileH)
region.flip(false, globalFlipY)
/*return*/region
})
}
}
fun get(x: Int, y: Int) = regions[y * horizontalCount + x]

View File

@@ -24,7 +24,7 @@
package net.torvald.terrarumsansbitmap.slick2d
import net.torvald.terrarumsansbitmap.gdx.GameFontBase
/*import net.torvald.terrarumsansbitmap.gdx.GameFontBase
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.JUNG_COUNT
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.JONG_COUNT
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.W_ASIAN_PUNCT
@@ -46,7 +46,7 @@ import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.SHEET_CJK_PUNCT
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.SHEET_UNIHAN
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.SHEET_CYRILIC_VARW
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.SHEET_FW_UNI
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.SHEET_UNI_PUNCT
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.SHEET_UNI_PUNCT_VARW
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.SHEET_GREEK_VARW
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.SHEET_THAI_VARW
import net.torvald.terrarumsansbitmap.gdx.GameFontBase.Companion.SHEET_HAYEREN_VARW
@@ -144,7 +144,7 @@ class GameFontBase(fontDir: String, val noShadow: Boolean = false) : Font {
private fun isUniHan(c: Char) = c.toInt() in codeRange[SHEET_UNIHAN]
private fun isCyrilic(c: Char) = c.toInt() in codeRange[SHEET_CYRILIC_VARW]
private fun isFullwidthUni(c: Char) = c.toInt() in codeRange[SHEET_FW_UNI]
private fun isUniPunct(c: Char) = c.toInt() in codeRange[SHEET_UNI_PUNCT]
private fun isUniPunct(c: Char) = c.toInt() in codeRange[SHEET_UNI_PUNCT_VARW]
private fun isGreek(c: Char) = c.toInt() in codeRange[SHEET_GREEK_VARW]
private fun isThai(c: Char) = c.toInt() in codeRange[SHEET_THAI_VARW]
private fun isDiacritics(c: Char) = c.toInt() in 0xE34..0xE3A
@@ -238,7 +238,7 @@ class GameFontBase(fontDir: String, val noShadow: Boolean = false) : Font {
SHEET_EXTA_VARW,
SHEET_EXTB_VARW,
SHEET_CYRILIC_VARW,
SHEET_UNI_PUNCT,
SHEET_UNI_PUNCT_VARW,
SHEET_GREEK_VARW,
SHEET_THAI_VARW,
SHEET_HAYEREN_VARW,
@@ -628,7 +628,7 @@ class GameFontBase(fontDir: String, val noShadow: Boolean = false) : Font {
else if (isCyrilic(c))
return SHEET_CYRILIC_VARW
else if (isUniPunct(c))
return SHEET_UNI_PUNCT
return SHEET_UNI_PUNCT_VARW
else if (isCJKPunct(c))
return SHEET_CJK_PUNCT
else if (isFullwidthUni(c))
@@ -686,7 +686,7 @@ class GameFontBase(fontDir: String, val noShadow: Boolean = false) : Font {
sheetX = fullwidthUniIndexX(ch)
sheetY = fullwidthUniIndexY(ch)
}
SHEET_UNI_PUNCT -> {
SHEET_UNI_PUNCT_VARW -> {
sheetX = uniPunctIndexX(ch)
sheetY = uniPunctIndexY(ch)
}
@@ -787,4 +787,4 @@ class GameFontBase(fontDir: String, val noShadow: Boolean = false) : Font {
val noColorCode = toColorCode(0x0000)
}
}
}*/

BIN
testing.PNG Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

10
testtext.txt Normal file
View File

@@ -0,0 +1,10 @@
re ʘ, ʇ, ʗ, and ʖ, al
ɓ ɗ ɠ
ɐ ɔ ə ɟ ɥ ɯ ɹ ʇ ʌ ʍ ʎ
Vʷ[kʰuˣt̪s̟] and Vʷ[kʰʉˣt͜ʃ].
ʡ̆
Labiodental flap [ⱱ] U+2C71
acegijmnopqrsuvwxyzɱɳʙɾɽʒʂʐʋɹɻɥɟɡɢʛȵɲŋɴʀɕʑçʝxɣχʁʜʍɰʟɨʉɯuʊøɘɵɤəɛœɜɞʌɔæɐɶɑɒɚɝɩɪʅʈʏʞⱥⱦⱱⱳⱴⱶⱷⱸⱺⱻ