DonationCoder.com forum
 
Read-only archive. This is a static copy of the DonationCoder.com forum. Reading and searching work as before; logging in, posting and private messages do not.
Archive of 2026-10-21 · About this archive · Main site

Author Topic: Request: fixes for geshi syntax formatter  (Read 7,703 times)

f0dder

  • [Well, THAT escalated quickly!]
  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,153
    • Participated in NANY Challenge Once
Request: fixes for geshi syntax formatter
« on: December 29, 2007, 01:39 AM »
The code syntax highlighter used on DC is very nice, but: copy-pasting from it is hell because of line numbering. A "place contents in clipboard" button for code blocks would be nice. And an option to specify number of spaces per tab would also be nice, if it's not already available...

Yeah I know, should probably be a request somewhere on SMF forum/mod page somewhere, but I can't be arsed to sign up for yet another forum :)
- carpe noctem

urlwolf

  • Charter Member
  • Joined in 2006
  • ***
  • Posts: 1,837
    • Gathering Badge
    • Linux User
Re: Request: fixes for geshi syntax formatter
« Reply #1 on: January 07, 2008, 06:14 PM »
+1

Lashiec

  • Member
  • Joined in 2006
  • **
  • Posts: 2,374
Re: Request: fixes for geshi syntax formatter
« Reply #2 on: January 07, 2008, 06:17 PM »
Use Opera, it does not have that problem ;D

f0dder

  • [Well, THAT escalated quickly!]
  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,153
    • Participated in NANY Challenge Once
Re: Request: fixes for geshi syntax formatter
« Reply #3 on: January 08, 2008, 12:33 AM »
Use Opera, it does not have that problem ;D
Opera doesn't copy line-numbers?

I wonder if that's a bug or a feature or correct handling of the HTML :)
- carpe noctem

jgpaiva

  • Artificial Idiocy
  • Global Moderator
  • Joined in 2006
  • *****
  • Posts: 4,727
    • Cody Award
    • Participated in NANY Challenge Once
    • Coding Snacks
    • Portugal Inhabitant
    • Linux User
Re: Request: fixes for geshi syntax formatter
« Reply #4 on: January 08, 2008, 01:19 AM »
No, selection on opera is done correcly, one space after the number.

Quote from: http://qbnz.com/highlighter/geshi-doc.html#line-numbers
For example, line numbers look nice, but when you go to select the code in your browser to copy it? You got the line numbers too! Not such a good thing, but thankfully this issue is now solved.
From the above quote, i think it means this is the correct behaviour ;)

f0dder

  • [Well, THAT escalated quickly!]
  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,153
    • Participated in NANY Challenge Once
Re: Request: fixes for geshi syntax formatter
« Reply #5 on: January 08, 2008, 01:16 PM »
Hm.

If I only select part of some code (ie, I make sure that I don't select "above" or "below" the code, as you're almost 100% guaranteed to do if you don't stop selection at second-last char (when selection down) or second char (when selection up), I don't get line numbers, but I get #-signs.
- carpe noctem

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 40,931
    • Gathering Badge
    • Plugin Coding Medal
    • Participated in NANY Challenge Seventeen Times
    • Cody Award
    • Coding Snacks
    • Volunteers/Staff
Re: Request: fixes for geshi syntax formatter
« Reply #6 on: April 27, 2009, 05:55 PM »
i'd like to fix this now.. looking into it.

Original address: https://www.donationcoder.com/forum/index.php?topic=11552.0