| View previous topic :: View next topic |
| Author |
Message |
passport
Joined: 20 Mar 2005 Posts: 17
|
Posted: Mon Mar 21, 2005 5:16 pm Post subject: Forum to show autohotkey syntax for {code} tag |
|
|
This would be a Very Good Thing. It would be great to see colorful syntax for ahk scripts when we use the {code} tag.
Edit: I'm talking about the forum web page obviously. |
|
| Back to top |
|
 |
Titan
Joined: 11 Aug 2004 Posts: 5390 Location: /b/
|
Posted: Mon Mar 21, 2005 5:41 pm Post subject: |
|
|
Also prehaps automatic linking to syntax and their respective documentation (e.g. MouseClick > MouseClick) unless you script a pure hotstring similar yourself
I don't really think it's worth it though  _________________
 |
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10480
|
Posted: Mon Mar 21, 2005 8:05 pm Post subject: |
|
|
This is a good wish and certainly something I'd like to see too. It's a little pie-in-the-sky, but maybe someone will come along someday who's knowledgeable enough in PHP scripting and with enough time on their hands to tackle something like this.
A couple have related topics have been mentioned before:
1) A script that transforms other scripts into colorized HTML for easier publishing on the web (I know this can be done with PSPad, but it would be nice to have a standalone script too).
2) Toralf's Syntax-Tidy for scripts (indentation and case correction) |
|
| Back to top |
|
 |
passport
Joined: 20 Mar 2005 Posts: 17
|
Posted: Tue Mar 22, 2005 5:27 pm Post subject: |
|
|
http://www.phpbb.com/phpBB/viewtopic.php?t=217723 looks promising.
| Quote: | | Syntax highlighting will allow users to use [syntax="language"]...[/syntax] to highlight code in just about any installed language, making for far more interesting posts than what boring [code] gives you. | I'll install a phpbb on my machine and test it out, play around, see if it's possible. It seems like the stock module doesn't support ahk syntax, for some reason. |
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10480
|
Posted: Tue Mar 22, 2005 10:45 pm Post subject: |
|
|
Cool. I'm glad someone's already laid the groundwork.
If you have any success, please post your findings here. |
|
| Back to top |
|
 |
passport
Joined: 20 Mar 2005 Posts: 17
|
Posted: Wed Mar 23, 2005 10:10 am Post subject: |
|
|
http://img224.exs.cx/img224/9296/screenshot5ow.png
http://img115.exs.cx/img115/271/screenshot24dn.png
After a couple of hours of fiddling around with it, I figured out how to do some basic highlighting in phpbb. Since authotkey syntax is strange, the default highlighter gives pretty much the same results I get with Editplus syntax highlighting for ahk.
| Quote: | | Also prehaps automatic linking to syntax and their respective documentation (e.g. MouseClick > MouseClick) |
Yes, that is possible and quite easy.
The module installation didn't take too long. But I tested the mod on a fresh phpbb installation.
Usage is nice.
[syntax="ahk"]ahkcode[/syntax]
What do you think? |
|
| Back to top |
|
 |
jonny
Joined: 13 Nov 2004 Posts: 3004 Location: Minnesota
|
Posted: Wed Mar 23, 2005 4:16 pm Post subject: |
|
|
| Looks very nice. I think this would be a great module to implement in this forum. |
|
| Back to top |
|
 |
Serenity
Joined: 07 Nov 2004 Posts: 1276
|
Posted: Wed Mar 23, 2005 5:04 pm Post subject: |
|
|
If this gets implemented I'd like an option in Profile to turn off syntax highlighting as I prefer it without. _________________ "Anything worth doing is worth doing slowly." - Mae West
 |
|
| Back to top |
|
 |
jonny
Joined: 13 Nov 2004 Posts: 3004 Location: Minnesota
|
Posted: Wed Mar 23, 2005 5:47 pm Post subject: |
|
|
| It looks like it would be an entirely new tag, and that the old code tag would still work the same. |
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10480
|
Posted: Wed Mar 23, 2005 9:32 pm Post subject: |
|
|
| passport wrote: | | After a couple of hours of fiddling around with it, I figured out how to do some basic highlighting in phpbb. | Thanks for your research and screenshots.
| Quote: | | Since AutoHotkey syntax is strange, the default highlighter gives pretty much the same results I get with Editplus syntax highlighting for ahk. | Yeah that's a drawback. The syntax is indeed strange from a programmer's point of view.
If you're willing to put even more effort into it, such as including all keywords and perhaps even making an script that automatically regenerates the syntax coloring module from the master syntax files in the Extras folder, that would be a boon.
When you're ready, I'd be grateful if you could send your work and some basic set-up instructions to support@autohotkey.com ... (at your leisure, since this is a low priority).
Thanks. |
|
| Back to top |
|
 |
|