Page MenuHomePhabricator

Use PEAR Text_Figlet to render figlet fonts
ClosedPublic

Authored by epriestley on Sep 13 2015, 6:50 PM.
Tags
None
Referenced Files
F14060047: D14102.diff
Sun, Nov 17, 11:05 PM
F14057938: D14102.id34087.diff
Sun, Nov 17, 8:13 AM
F14051711: D14102.id.diff
Fri, Nov 15, 3:05 AM
F14049381: D14102.diff
Thu, Nov 14, 12:50 PM
F14045012: D14102.id34081.diff
Tue, Nov 12, 11:56 PM
F14039968: D14102.id34081.diff
Mon, Nov 11, 6:55 AM
F14036432: D14102.diff
Sun, Nov 10, 10:14 AM
F14029529: D14102.id34087.diff
Fri, Nov 8, 8:47 PM
Subscribers
None

Details

Summary

Ref T7785. Makes Figlet available without installing the figlet package.

The PEAR Text_Figlet code is really sketchy and includes this API, which is quite marvelous:

function loadFont($filename, $loadgerman = true)

At some point, this should probably be rewritten into a modern style, but it's not trivial since the figlet file format and rendering engine are somewhat complicated. I made some adjustments:

  • Broke the dependency on the PEAR core.
  • Prevented it from doing any wrong HTML escaping.
  • Looked through it for any glaring security or correctness problems.

This code isn't very pretty or modern, but as far as I can tell it's safe and does render Figlet fonts in a reasonable way.

Test Plan

Screen Shot 2015-09-13 at 11.44.43 AM.png (805×1 px, 94 KB)

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

epriestley retitled this revision from to Use PEAR Text_Figlet to render figlet fonts.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
This revision is now accepted and ready to land.Sep 13 2015, 7:29 PM
This revision was automatically updated to reflect the committed changes.