Skip to content

Instantly share code, notes, and snippets.

@andreasplesch
Last active March 29, 2025 15:18
Show Gist options
  • Select an option

  • Save andreasplesch/dc9111dcd106f1a69d567ceca8f52701 to your computer and use it in GitHub Desktop.

Select an option

Save andreasplesch/dc9111dcd106f1a69d567ceca8f52701 to your computer and use it in GitHub Desktop.
Test new FontStyle.url field for custom fonts
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 4.1//EN" "https://www.web3d.org/specifications/x3d-4.1.dtd">
<X3D profile='Full' version='4.1' xmlns:xsd='http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation='https://www.web3d.org/specifications/x3d-4.1.xsd'>
<head>
<meta content='TextHaveFunWithX3D.x3d' name='title'/>
<meta content='Simple smiley-face example illustrating an emoticon character entity, used within an MFString Text.' name='description'/>
<meta content='Don Brutzman' name='creator'/>
<meta content='26 April 2017' name='created'/>
<meta content='18 June 2024' name='modified'/>
<meta content='27 Feb 2023' name='modified'/>
<meta content='new FontStyle.url for custom fonts' name='modified'/>
<meta content='TextHaveFunWithX3D.png' name='Image'/>
<meta content='[x3d-public] special characters and fonts: extending FontStyle family/url for font file' name='reference'/>
<meta content='https://web3d.org/pipermail/x3d-public_web3d.org/2024-May/020447.html' name='reference'/>
<meta content='http://unicode.org/emoji/charts/full-emoji-list.html' name='reference'/>
<meta content='https://en.wikipedia.org/wiki/Emoticons_(Unicode_block)' name='reference'/>
<meta content='https://en.wikipedia.org/wiki/Universal_Character_Set_characters' name='reference'/>
<meta content='https://www.w3.org/TR/html4/sgml/entities.html' name='reference'/>
<meta content='https://dev.w3.org/html5/html-author/charref' name='reference'/>
<meta content='https://www.w3.org/wiki/Common_HTML_entities_used_for_typography' name='reference'/>
<meta content='Wikipedia: Web typography https://en.wikipedia.org/wiki/Web_typography#Web_fonts' name='reference'/>
<meta content='Fonts on the Web https://www.w3.org/Fonts' name='reference'/>
<meta content='History of the Web: The Decade-Long Path to Web Fonts https://thehistoryoftheweb.com/web-fonts' name='reference'/>
<meta content='https://X3dGraphics.com' name='reference'/>
<meta content='https://create3000.github.io/x_ite/components/text/fontstyle/#supported-file-formats' name='reference'/>
<meta content='TextHaveFunWithX3D_SerifX_ITE.png' name='Image'/>
<meta content='https://www.web3d.org/x3d/content/examples/X3dResources.html' name='reference'/>
<meta content='Copyright Don Brutzman and Leonard Daly 2007' name='rights'/>
<meta content='emoji emoticon, X3D book, X3D graphics, X3D-Edit, http://www.x3dGraphics.com' name='subject'/>
<meta content='https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter02GeometryPrimitives/TextHaveFunWithX3D.x3d' name='identifier'/>
<meta content='X3D-Edit 4.0, https://savage.nps.edu/X3D-Edit' name='generator'/>
<meta content='../license.html' name='license'/>
</head>
<Scene>
<WorldInfo title='TextHaveFunWithX3D.x3d'/>
<Background skyColor='0.819608 0.984314 1'/>
<Shape>
<!-- &#9786; = smiley face emoticon, and "" means skip a line -->
<Text string='"" "Have fun" "with X3D!" "" ":) ☺"'>
<FontStyle spacing='1.5' family='"Playwright_CA_Guides"' url='"https://fonts.gstatic.com/s/playwritecaguides/v1/MjQamj1kuP_soQ3o-rysO9Ci_8oJlIUUInI.woff2"' justify='"MIDDLE" "MIDDLE"' />
</Text>
<Appearance>
<Material ambientIntensity='0.25' diffuseColor='0 0.251004 0.239248' shininess='0.06' specularColor='0.177935 0.249369 0.229278'>
<!-- Universal Media Library: ArtDeco 19 -->
</Material>
</Appearance>
</Shape>
</Scene>
</X3D>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 4.1//EN" "https://www.web3d.org/specifications/x3d-4.1.dtd">
<X3D profile='Full' version='4.1' xmlns:xsd='http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation='https://www.web3d.org/specifications/x3d-4.1.xsd'>
<head>
<component name='Text' level='1'/>
<meta content='TextHaveFunWithX3D.x3d' name='title'/>
<meta content='Simple smiley-face example illustrating an emoticon character entity, used within an MFString Text.' name='description'/>
<meta content='Don Brutzman' name='creator'/>
<meta content='26 April 2017' name='created'/>
<meta content='18 June 2024' name='modified'/>
<meta content='27 Feb 2023' name='modified'/>
<meta content='FontLibrary for custom fonts' name='modified'/>
<meta content='TextHaveFunWithX3D.png' name='Image'/>
<meta content='[x3d-public] special characters and fonts: extending FontStyle family/url for font file' name='reference'/>
<meta content='https://web3d.org/pipermail/x3d-public_web3d.org/2024-May/020447.html' name='reference'/>
<meta content='http://unicode.org/emoji/charts/full-emoji-list.html' name='reference'/>
<meta content='https://en.wikipedia.org/wiki/Emoticons_(Unicode_block)' name='reference'/>
<meta content='https://en.wikipedia.org/wiki/Universal_Character_Set_characters' name='reference'/>
<meta content='https://www.w3.org/TR/html4/sgml/entities.html' name='reference'/>
<meta content='https://dev.w3.org/html5/html-author/charref' name='reference'/>
<meta content='https://www.w3.org/wiki/Common_HTML_entities_used_for_typography' name='reference'/>
<meta content='Wikipedia: Web typography https://en.wikipedia.org/wiki/Web_typography#Web_fonts' name='reference'/>
<meta content='Fonts on the Web https://www.w3.org/Fonts' name='reference'/>
<meta content='History of the Web: The Decade-Long Path to Web Fonts https://thehistoryoftheweb.com/web-fonts' name='reference'/>
<meta content='https://X3dGraphics.com' name='reference'/>
<meta content='https://create3000.github.io/x_ite/components/text/fontstyle/#supported-file-formats' name='reference'/>
<meta content='TextHaveFunWithX3D_SerifX_ITE.png' name='Image'/>
<meta content='https://www.web3d.org/x3d/content/examples/X3dResources.html' name='reference'/>
<meta content='Copyright Don Brutzman and Leonard Daly 2007' name='rights'/>
<meta content='emoji emoticon, X3D book, X3D graphics, X3D-Edit, http://www.x3dGraphics.com' name='subject'/>
<meta content='https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter02GeometryPrimitives/TextHaveFunWithX3D.x3d' name='identifier'/>
<meta content='X3D-Edit 4.0, https://savage.nps.edu/X3D-Edit' name='generator'/>
<meta content='../license.html' name='license'/>
</head>
<Scene>
<WorldInfo title='TextHaveFunWithX3D.x3d'/>
<FontLibrary family='Playwright_CA_Guides' url='"https://fonts.gstatic.com/s/playwritecaguides/v1/MjQamj1kuP_soQ3o-rysO9Ci_8oJlIUUInI.woff2"'/>
<Background skyColor='0.819608 0.984314 1'/>
<Shape>
<!-- &#9786; = smiley face emoticon, and "" means skip a line -->
<Text string='"" "Have fun" "with X3D!" "" ":) ☺"'>
<FontStyle spacing='1.5' family='"Playwright_CA_Guides"' justify='"MIDDLE" "MIDDLE"' />
</Text>
<Appearance>
<Material ambientIntensity='0.25' diffuseColor='0 0.251004 0.239248' shininess='0.06' specularColor='0.177935 0.249369 0.229278'>
<!-- Universal Media Library: ArtDeco 19 -->
</Material>
</Appearance>
</Shape>
</Scene>
</X3D>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment