summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--paste/include/pastify.inc12
1 files changed, 10 insertions, 2 deletions
diff --git a/paste/include/pastify.inc b/paste/include/pastify.inc
index 8103a7d..92253c9 100644
--- a/paste/include/pastify.inc
+++ b/paste/include/pastify.inc
@@ -44,11 +44,19 @@ function PastifyText($text, $language, $desc, $get_url, $remove_url)
# Do the actual syntax highlighting
$geshi = new GeSHi($text, $language);
$geshi->enable_line_numbers(GESHI_FANCY_LINE_NUMBERS);
- $geshi->set_header_type(GESHI_HEADER_PRE_TABLE);
+ $geshi->set_line_style('font-size: 0.8em; color: #999;', 'font-size: 0.8em; color: #000;');
+ $geshi->set_code_style('margin-left: 1em; color: #000; font-size: 1.3em;', true);
- $geshi->set_footer_content('<div style="font-size: 0.5em; color: #DDD; text-align: center;">Rendered in {TIME}s with GeSHi {VERSION}</div>');
+ $geshi->set_header_type(GESHI_HEADER_DIV);
+
+ $geshi->set_footer_content('Rendered in {TIME}s with GeSHi {VERSION}');
+ $geshi->set_footer_content_style('font-size: 0.5em; color: #DDD; text-align: center;');
$geshi->set_overall_style('width: 100%;');
+ if (isset($_REQUEST['hl'])) {
+ $geshi->highlight_lines_extra(explode(',', $_REQUEST['hl']));
+ }
+
$output = $geshi->parse_code();
$html = <<<EOH