Advertisement:

Author Topic: GeSHiSmf  (Read 82561 times)

Offline AzaToth

  • Jr. Member
  • **
  • Posts: 276
  • Gender: Male
GeSHiSmf
« on: September 25, 2005, 06:50:16 PM »
Link to Mod

A implementation of GeSHI (Generic Syntax Highlighter) for SMF

This is a modification that replace the ordinary code tags, to enable them to syntax highlight code other than php. This is done by parsing the code throught GeSHi and print the result in the post. Support is for  languages like perl, html, c, qbasic etc...

Quote from: GeSHi homepage (http://qbnz.com/highlighter/)
GeSHi started as an idea to create a generic syntax highlighter for the phpBB forum system, but has been generalised to this project. GeSHi aims to be a simple but powerful highlighting class, with the following goals:

    * Support for a wide range of popular languages
    * Easy to add a new language for highlighting
    * Highly customisable output formats

GeSHi aims to do this all as quickly as possible. Many customisable features of GeSHi facilitate speed increases, and you can easily find a balance between the amount of highlighting done and the speed in which it is done.

Supported languages:
  • Actionscript
  • ADA
  • Apache Log
  • AppleScript
  • ASM
  • ASP
  • Bash
  • C
  • C for Macs
  • C#
  • C++
  • CAD DCL
  • CadLisp
  • CSS
  • Delphi
  • DIV
  • DOS
  • Eiffel
  • FreeBasic
  • GML
  • HTML
  • Inno
  • Java
  • Javascript
  • Lisp
  • Lua
  • Microprocessor ASM
  • NSIS
  • Objective C
  • OCaml
  • OpenOffice BASIC
  • Oracle 8 SQL
  • Pascal
  • Perl
  • PHP
  • Python
  • Q(uick)BASIC
  • Ruby
  • Scheme
  • SDLBasic
  • Smarty
  • SQL
  • VB.NET
  • Visual BASIC
  • Visual Fox Pro
  • XML


Example:



Usage:

[code=perl]my $var = undef;[/code]


One pulldown menu in default and classic is also implemented:


Only tested on vanilla 1.1 RC1
« Last Edit: September 25, 2005, 07:16:16 PM by AzaToth »

Offline ExistenZ

  • Jr. Member
  • **
  • Posts: 317
  • Gender: Male
  • Hip2b²
    • Virtual Hogwarts
Re: GeSHiSmf
« Reply #1 on: September 25, 2005, 07:17:06 PM »
WOW! I have been waiting for this ll my life! THANK YOU!
Regards,
Andre

Offline ANARCH¥

  • Semi-Newbie
  • *
  • Posts: 80
Re: GeSHiSmf
« Reply #2 on: September 25, 2005, 07:26:35 PM »
arghhh i want this ... for SMF 1.0 RC2.
lol

hmmm sry

Offline AzaToth

  • Jr. Member
  • **
  • Posts: 276
  • Gender: Male
Re: GeSHiSmf
« Reply #3 on: September 25, 2005, 07:47:19 PM »
arghhh i want this ... for SMF 1.0 RC2.
lol

hmmm sry
a reason to upgrade :)

Offline Jazhawk

  • Full Member
  • ***
  • Posts: 497
  • Gender: Male
Re: GeSHiSmf
« Reply #4 on: September 25, 2005, 10:58:00 PM »
What does this do exactly?

-Jazhawk

Offline JayBachatero

  • SMF Friend
  • SMF Super Hero
  • *
  • Posts: 19,562
  • Gender: Male
    • @jaycreations on Twitter
    • JayBachatero.com
Re: GeSHiSmf
« Reply #5 on: September 25, 2005, 11:30:11 PM »
What does this do exactly?

-Jazhawk

You can use it to highlight syntax code for other programming languages other than php.
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

Offline Enc0der

  • Jr. Member
  • **
  • Posts: 358
  • Gender: Male
  • I'm a llama!
Re: GeSHiSmf
« Reply #6 on: September 26, 2005, 04:33:08 AM »
awesome!

Offline AzaToth

  • Jr. Member
  • **
  • Posts: 276
  • Gender: Male
Re: GeSHiSmf
« Reply #7 on: September 26, 2005, 09:37:19 AM »
If anyone have problem with uninstalling this mod please tell me, if you do not have problem with uninstalling then there is a bug in SMF and you should contact [unknown].

Offline Phoenix Man

  • Semi-Newbie
  • *
  • Posts: 14
Re: GeSHiSmf
« Reply #8 on: September 26, 2005, 12:23:48 PM »
Nice.
Just a small add-on, but would you like to add support for the DM language as well?

It's the standard BYOND language. http://developer.byond.com/ [nofollow]

Offline AzaToth

  • Jr. Member
  • **
  • Posts: 276
  • Gender: Male
Re: GeSHiSmf
« Reply #9 on: September 26, 2005, 01:20:49 PM »
Nice.
Just a small add-on, but would you like to add support for the DM language as well?

It's the standard BYOND language. http://developer.byond.com/
That I'm sorry you have to speak to the GeSHi developer (http://qbnz.com/highlighter), I have just make the interface for smf.

Offline ArkServer

  • SMF Hero
  • ******
  • Posts: 1,831
  • My posts are my own
    • BlushyFace | A spoopy and creppy site
Re: GeSHiSmf
« Reply #10 on: September 26, 2005, 01:28:37 PM »
Could be me.. there is no install option for 1.1 beta 3

Offline AzaToth

  • Jr. Member
  • **
  • Posts: 276
  • Gender: Male
Re: GeSHiSmf
« Reply #11 on: September 26, 2005, 01:38:09 PM »
Could be me.. there is no install option for 1.1 beta 3
Thats because I have no beta3 installation, I don't know exactly whats the difference for RC1 and beta3 is for this kind of mod, You can try to substitute RC 1 to beta 3 Public and see if it works...

Offline ArkServer

  • SMF Hero
  • ******
  • Posts: 1,831
  • My posts are my own
    • BlushyFace | A spoopy and creppy site
Re: GeSHiSmf
« Reply #12 on: September 26, 2005, 03:49:27 PM »
Could be me.. there is no install option for 1.1 beta 3
Thats because I have no beta3 installation, I don't know exactly whats the difference for RC1 and beta3 is for this kind of mod, You can try to substitute RC 1 to beta 3 Public and see if it works...

oh ok, it says it 's compatible with 1.1 beta 3 but  nevermind :P ill keep an eye open for this topic in case you make it 1.1 beta 3 compatible



Offline AzaToth

  • Jr. Member
  • **
  • Posts: 276
  • Gender: Male
Re: GeSHiSmf
« Reply #13 on: September 26, 2005, 03:53:33 PM »
Could be me.. there is no install option for 1.1 beta 3
Thats because I have no beta3 installation, I don't know exactly whats the difference for RC1 and beta3 is for this kind of mod, You can try to substitute RC 1 to beta 3 Public and see if it works...

oh ok, it says it 's compatible with 1.1 beta 3 but  nevermind :P ill keep an eye open for this topic in case you make it 1.1 beta 3 compatible

I had to choose one, and 1.1 RC1 option isn't there, sorry...


Offline Bosswaiter

  • Semi-Newbie
  • *
  • Posts: 20
Re: GeSHiSmf
« Reply #14 on: September 28, 2005, 04:39:04 AM »
VERY nice and very helpful !

Only changed the css (smaller font + no maximum lines) for improved reading.

.geshi {
   color: #000000;
   background-color: #cccccc;
   font-family: monospace;
   font-size: small;
   border: 1px solid #000000;
   margin: 1px auto 1px auto;
   padding: 1px;
   width: 99%;
   overflow: auto;
   white-space: pre;
}

Offline ArkServer

  • SMF Hero
  • ******
  • Posts: 1,831
  • My posts are my own
    • BlushyFace | A spoopy and creppy site
Re: GeSHiSmf
« Reply #15 on: September 30, 2005, 07:20:04 AM »
Any update?

Offline dtm.exe

  • SMF Hero
  • ******
  • Posts: 5,465
Re: GeSHiSmf
« Reply #16 on: September 30, 2005, 08:12:54 AM »
Nice mod :).

Offline v3x

  • Semi-Newbie
  • *
  • Posts: 15
  • AMXX Coder
    • GHW AMXX Scripting Community
Re: GeSHiSmf
« Reply #17 on: October 02, 2005, 02:04:06 AM »
Can this be updated for the newest SMF version?

Offline AzaToth

  • Jr. Member
  • **
  • Posts: 276
  • Gender: Male
Re: GeSHiSmf
« Reply #18 on: October 02, 2005, 10:03:40 AM »
Can this be updated for the newest SMF version?
It's for SFM 1.1 RC1, it's says "Compatible for 1.1 beta3" because  the mod-section isn't updated yet.

Offline v3x

  • Semi-Newbie
  • *
  • Posts: 15
  • AMXX Coder
    • GHW AMXX Scripting Community
Re: GeSHiSmf
« Reply #19 on: October 02, 2005, 10:10:57 AM »
Will it interfere with any of my currently installed mods? Like for example, the arcade button and such.

Edit: I'm talking about the upgrade, not this mod.