Formatting code in the forum
Hi,
Phil Pilgrim has created a cool web applet that he is hosting on his site that allows you to paste SX assembly code into it and it will create text with all the formatting necessary to display properly. However, when I tried using it, the tabbed text didn't line up. Fill explained that the problem is part of the style sheet used in the forum software. See this post:
http://forums.parallax.com/showthread.php?p=636532
I have two questions:
1 - Can someone at Parallax modify the style sheet to follow Phil's suggestion? It will make formatted code line up correctly on pretty much everyone's system. He also has set it up so that the custom Parallax font is first, which means that Propeller code would format right if the user had that font installed.
2 - Can Phil's applet be integrated into the forum software so that we have a means of formatting code for the best possible display?
Thanks,
PeterM
Phil Pilgrim has created a cool web applet that he is hosting on his site that allows you to paste SX assembly code into it and it will create text with all the formatting necessary to display properly. However, when I tried using it, the tabbed text didn't line up. Fill explained that the problem is part of the style sheet used in the forum software. See this post:
http://forums.parallax.com/showthread.php?p=636532
I have two questions:
1 - Can someone at Parallax modify the style sheet to follow Phil's suggestion? It will make formatted code line up correctly on pretty much everyone's system. He also has set it up so that the custom Parallax font is first, which means that Propeller code would format right if the user had that font installed.
2 - Can Phil's applet be integrated into the forum software so that we have a means of formatting code for the best possible display?
Thanks,
PeterM
Comments
1) keep the hard spaces in the enclosed text.
2) convert tabbed text to hard spaces.
2) set a font style that formats, and looks good for all users.
Bob
I tested these settings with the following Propeller Spin code snippet, as pasted from my Spin formatter at www.phipi.com/format:
The numbers after the pound signs are translations from the original Unicode graphic characters performed by the formatter. Here is a screenshot of how it reconstructed in the forum in user mode while I was editing this post:
So what conclusions can be drawn from this? Here's what I think:
1. 11 points may be too big a font for general use in the forum's code blocks, because the text takes up so much screen real estate.
2. Even though the Propeller font looks good, it's hard to recommend it for general forum use, since it doesn't scale well below 11 points.
3. Nonetheless, people can still set up their own user mode .css file, if they're dead set on seeing a special font in the forum.
4. But the simplest solution to most people's code display issues is just to install Lucinda Console on their systems.
-Phil
Post Edited (Phil Pilgrim (PhiPi)) : 3/12/2007 7:41:32 AM GMT