• 
      

    Support custom syntax highlighting in the diff viewer

    Review Request #1180 — Created Oct. 25, 2009 and discarded — Latest diff uploaded

    Information

    djs
    Review Board
    master

    Reviewers

    Pygments supports lots of styles, but RB currently only supports its own simple syntax highlighting. This is a first step toward supporting custom syntax highlighting. Just looking for comments on the approach.
    
    * Add a script to generate all available pygment highlighters as static CSS files
    * Add an admin field to choose the desired style
    * Update templates to use a selector for the syntax highlighting
    
    This change works well enough with light-background styles, but not with dark-background styles. We'd need to support styling the changed line backgrounds based on the colorscheme of the theme for this to work well. Also needs a drop-down for selecting styles, css to be automatically generated on install, and user-selectable themes.
    
    http://github.com/djs/reviewboard/tree/review-1180
    Unit tests pass. Tested diff fragments and review comment fragments with different pygments color schemes. Tested generating a new database.