Editing
EDF font reference
From Eternity Wiki
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
The font is defined in EDF as follows: font ''name'' { id ''number'' start ''character'' end ''character'' linesize ''number'' usespacesize ''true/false'' spacesize ''number'' widthdelta ''number'' tallestchar ''number'' blockcentered ''true/false'' centerwidth ''number'' linearformat ''text'' linearlump ''identifier'' requantize ''true/false'' colorable ''true/false'' uppercase ''true/false'' patchnumoffset ''integer'' filter ''block'' defaultcolor ''color'' normalcolor ''color'' highlightcolor ''color'' errorcolor ''color'' colortables ''table'' } Font names have maximum 128 characters. A font delta structure is available, allowing you to modify an already defined font. Its definition is: fontdelta { name ''font_name'' ''fields'' } where ''font_name'' is the name of a previously fully defined <code>font</code>, and ''fields'' are the same fields as in a <code>font</code>'s definition. Only include the fields you intend to modify over the original font. ==Properties== {|class="wikitable sortable" !Key !Description |- ||'''id'''||Currently unused, it was needed for the now-disabled Small scripting system. |- ||'''start'''||First character in font. Can be either a character or an ASCII number. |- ||'''end'''||Last character in font. Can be either a character or an ASCII number. |- ||'''linesize'''||Text line height. |- ||'''usespacesize'''||Whether to use '''spacesize''' distance for space size, instead of the character graphics. |- ||'''spacesize'''||Width of space character, if '''usespacesize''' is '''true'''. |- ||'''widthdelta'''||Width delta: how much to reduce the width of each character. |- ||'''tallestchar'''||Absolute height: the height of the tallest font character. |- ||'''blockcentered'''||Whether characters are centered in position. |- ||'''centerwidth'''||Centered width, constant width, used only when '''blockcentered''' is on. |- ||'''linearformat'''||Unused. Now the format is determined from the content of the '''linearlump''' |- ||'''linearlump'''||Name of graphics lump which contains all characters. It can be a raw format or a Doom GFX format. |- ||'''requantize'''||In case of PNG lump, requantize to the palette. |- ||'''colorable'''||Whether font color can be changed. |- ||'''uppercase'''||Whether font uses uppercase only. |- ||'''patchnumoffset'''||An optional value to subtract from a character's ASCII value to determine the name that gets into the lump name. Applies only with '''filter''', not '''linearlump'''. |- ||'''filter'''||If not using a '''linearlump''', one or more of this field is required. A '''filter''' is a section which can look like this: filter { chars { ''list_of_characters'' }; mask ''format'' } or filter { start ''character''; end ''character''; mask ''format'' } depending on whether you want to filter for specific characters, or for a range. For the <code>chars</code> list, you put the components with commas (<code>,</code>) in-between. Each character can be expressed as a literal one, or as an ASCII value. <code>mask</code> is the name of the lump, with placeholder for the given character. Each placeholder can look like the following: *<code>%.3d</code>: ASCII number padded by up to three zeros. You can put other values instead of 3. *<code>%c</code>: the character itself. *<code>%i</code>: ASCII number, not padded. *<code>%02X</code>: ASCII number encoded in hexadecimal (base 16 number, with A, B, C, D, E, F representing 10-15). This one is padded with up to two zeros. You can put other values instead of 2. You can also choose not to put any placeholder if you have an exact lump name. Beware of '''patchnumoffset'''. If set, then you need to subtract it from the real ASCII value, to get the value in the lump name. |- ||'''defaultcolor'''||Default font color. See the color keywords section in this page for details. |- ||'''normalcolor'''||Normal font color. See the color keywords section in this page for details. |- ||'''highlightcolor'''||Highlight font color. See the color keywords section in this page for details. |- ||'''errorcolor'''||Error font color. See the color keywords section in this page for details. |- ||'''colortables'''||This is a block looking like this: { ''color_name'' ''translation_list'' ''color_name'' ''translation_list'' ... } Each ''color_name'' is one of the color names specified in the "color names" section of this page. ''Translation_list'' can either be <code>@identity</code>, in which case it performs no translation, or a comma-separated list of <code>''n1'':''n2''=''n3'':''n4''</code> pairs, or <code>''n1''=''n3''</code> pairs, which set what palette colors (or ranges thereof) to change to what. |} ==Color names== The color fields allow one the following values: brick, tan, gray, green, brown, gold, red, blue, orange, yellow, custom1, custom2, custom3, custom4. [[Category:EDF]]
Summary:
Please note that all contributions to Eternity Wiki are considered to be released under the GNU Free Documentation License 1.2 (see
Eternity Wiki:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Page actions
Page
Discussion
Read
Edit
History
Page actions
Page
Discussion
More
Tools
Personal tools
Not logged in
Talk
Contributions
Log in
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Search
Tools
What links here
Related changes
Special pages
Page information