Opened 16 years ago

Closed 15 years ago

#1944 closed defect (duplicate)

Doesn't highlight unless you have a session

Reported by: Alec Thomas Owned by: Matt Good
Priority: normal Component: TracPygmentsPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.10


This patch fixed it on TracHacks:


    old new  
    131131    def post_process_request(self, req, template, content_type):
    132132        if not getattr(req, '_no_pygments_stylesheet', False):
     133            if req.session:
     134                style = req.session.get('pygments_style', self.default_style)
     135            else:
     136                style = self.default_style
    133137            add_link(req, 'stylesheet', self.env.href('pygments', '%s.css' %
    134                      req.session.get('pygments_style', self.default_style)))
     138                     style))
    135139        return template, content_type
    137141    # IRequestHandler implementation

Attachments (0)

Change History (3)

comment:1 Changed 16 years ago by Alec Thomas

Summary: Doesn't render unless you have a sessionDoesn't highlight unless you have a session

comment:2 Changed 15 years ago by Giel van Schijndel

This is a duplicate of #1336.

comment:3 Changed 15 years ago by Giel van Schijndel

Resolution: duplicate
Status: newclosed

Modify Ticket

Change Properties
Set your email in Preferences
as closed The owner will remain Matt Good.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment

E-mail address and name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.