#6921 Enable 'startinline' option for better PHP code highlighting

unreleased
open
nobody
None
General
nobody
2015-03-05
2013-11-26
No

Pygment's PhpLexer has a 'startinline' option so that the '<?php' preamble isn't needed. I think that would be helpful almost all the time (frequently code snippets of php don't have that). Can we turn it on as part of the markdown extension?

Discussion

  • Dave Brondsema

    Dave Brondsema - 2014-02-03
    • Labels: --> 42cc
    • Status: open --> in-progress
     
  • Igor Bondarenko - 2014-02-04

    Seems like we'll need to implement own codehilite-like extension to do that. It'll involve subclassing a couple of codehilite classes and some copypaste from them. Don't sure if it worth it.

     
  • Dave Brondsema

    Dave Brondsema - 2014-02-04

    Okay, I guess I was hoping there would be a somewhat simple way to enable that option through our existing markdown extension setup. If, as you say, it'll be complex and ugly, and take a fair bit of time to set up now (and in the future to maintain extra layers of code), then we shouldn't spend time working on it now.

     
  • Igor Bondarenko - 2014-02-05

    Yeah, seems like this is the only way. Codehilite doesn't provide any options to configure lexers.

    Closed #529 on our side.

     
  • Dave Brondsema

    Dave Brondsema - 2014-02-05
    • labels: 42cc -->
    • status: in-progress --> open
    • Milestone: forge-backlog --> limbo
     

Log in to post a comment.