Skip to content

Commit 8d10c81

Browse files
committed
use wildcard CSS prefix matching for div id src
fixes #716
1 parent b001a5a commit 8d10c81

File tree

3 files changed

+38
-38
lines changed

3 files changed

+38
-38
lines changed

web/default/style.css

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -458,18 +458,18 @@ table#dirlist { /* the "Name" column */
458458
}
459459

460460
/* file display */
461-
#src {
461+
div[id^='src'] {
462462
}
463463

464-
#src pre {
464+
div[id^='src'] pre {
465465
margin: 0;
466466
}
467467

468-
#src .l-hide, #src .hl-hide, .blame-hidden { /* hidden line number/annotation block */
468+
div[id^='src'] .l-hide, #src .hl-hide, .blame-hidden { /* hidden line number/annotation block */
469469
display: none
470470
}
471471

472-
#src .l, #src .hl, .blame .r, .blame .a,
472+
div[id^='src'] .l, div[id^='src'] .hl, .blame .r, .blame .a,
473473
#results .l, #more .l,
474474
#difftable i, del.d { /* line number/annotation block */
475475
display: inline-block;
@@ -481,12 +481,12 @@ table#dirlist { /* the "Name" column */
481481
color: #666;
482482
}
483483

484-
#src .hl { /* highlighted line number */
484+
div[id^='src'] .hl { /* highlighted line number */
485485
color: #000;
486486
}
487487

488488
/* highlight line number with anchor */
489-
#src a.l:target, #src a.hl:target {
489+
div[id^='src'] a.l:target, div[id^='src'] a.hl:target {
490490
background: orange;
491491
color:yellow;
492492
}
@@ -500,12 +500,12 @@ table#dirlist { /* the "Name" column */
500500
}
501501

502502
/* source code highlighting - see org/opengrok/analysis/$lang/*Xref.lex */
503-
#src .n { /* numbers/label */ color: #a52a2a; }
504-
#src .s { /* strings */ color: green; }
505-
#src .c { /* comment */ color: #666; }
506-
#src .b { /* heading/title/bold */ color: #000; font-weight: bold; }
507-
#src .k { /* block display */ color: #000; font-family: monospace; }
508-
#src a.d { /* symbol definition */ color: #909; font-weight: bold; }
503+
div[id^='src'] .n { /* numbers/label */ color: #a52a2a; }
504+
div[id^='src'] .s { /* strings */ color: green; }
505+
div[id^='src'] .c { /* comment */ color: #666; }
506+
div[id^='src'] .b { /* heading/title/bold */ color: #000; font-weight: bold; }
507+
div[id^='src'] .k { /* block display */ color: #000; font-family: monospace; }
508+
div[id^='src'] a.d { /* symbol definition */ color: #909; font-weight: bold; }
509509

510510
a.xm { /* macro */ color: #c66; font-weight: bold; }
511511
a.xa { /* argument */ color: #60c; font-weight: bold; }
@@ -609,7 +609,7 @@ a.xsr { /* subroutine */ color: #00f; font-weight: bold; }
609609
}
610610

611611
#results .con .all {
612-
margin-left: 6ex; /* width(#src .l) + 1ex */
612+
margin-left: 6ex; /* width(div[id^='src'] .l) + 1ex */
613613
}
614614

615615
#results .s, #more .s { /* matched line contents */

web/offwhite/style.css

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -496,18 +496,18 @@ table#dirlist { /* the "Name" column */
496496

497497

498498
/* file display */
499-
#src {
499+
div[id^='src'] {
500500
}
501501

502-
#src pre {
502+
div[id^='src'] pre {
503503
margin: 0;
504504
}
505505

506-
#src .l-hide, #src .hl-hide, .blame-hidden { /* hidden line number/annotation block */
506+
div[id^='src'] .l-hide, div[id^='src'] .hl-hide, .blame-hidden { /* hidden line number/annotation block */
507507
display: none
508508
}
509509

510-
#src .l, #src .hl, .blame .r, .blame .a,
510+
div[id^='src'] .l, div[id^='src'] .hl, .blame .r, .blame .a,
511511
#results .l, #more .l,
512512
#difftable i, del.d { /* line number/annotation block */
513513
display: inline-block;
@@ -520,12 +520,12 @@ table#dirlist { /* the "Name" column */
520520
color: #888;
521521
}
522522

523-
#src .hl { /* highlighted line number */
523+
div[id^='src'] .hl { /* highlighted line number */
524524
color: #000;
525525
}
526526

527527
/* highlight line number with anchor */
528-
#src a.l:target, #src a.hl:target {
528+
div[id^='src'] a.l:target, div[id^='src'] a.hl:target {
529529
background: orange;
530530
color:yellow;
531531
}
@@ -539,12 +539,12 @@ table#dirlist { /* the "Name" column */
539539
}
540540

541541
/* source code highlighting - see org/opengrok/analysis/$lang/*Xref.lex */
542-
#src .n { /* numbers/label */ color: #a52a2a; }
543-
#src .s { /* strings */ color: green; }
544-
#src .c { /* comment */ color: #666; }
545-
#src .b { /* heading/title/bold */ color: #000; font-weight: bold; }
546-
#src .k { /* block display */ color: #000; font-family: monospace; }
547-
#src a.d { /* symbol definition */ color: #909; font-weight: bold; }
542+
div[id^='src'] .n { /* numbers/label */ color: #a52a2a; }
543+
div[id^='src'] .s { /* strings */ color: green; }
544+
div[id^='src'] .c { /* comment */ color: #666; }
545+
div[id^='src'] .b { /* heading/title/bold */ color: #000; font-weight: bold; }
546+
div[id^='src'] .k { /* block display */ color: #000; font-family: monospace; }
547+
div[id^='src'] a.d { /* symbol definition */ color: #909; font-weight: bold; }
548548

549549
a.xm { /* macro */ color: #c66; font-weight: bold; }
550550
a.xa { /* argument */ color: #60c; font-weight: bold; }

web/polished/style.css

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -552,19 +552,19 @@ table#dirlist { /* the "Name" column */
552552

553553

554554
/* file display */
555-
#src {
555+
div[id^='src'] {
556556
background: white;
557557
}
558558

559-
#src pre {
559+
div[id^='src'] pre {
560560
margin: 0;
561561
}
562562

563-
#src .l-hide, #src .hl-hide, .blame-hidden { /* hidden line number/annotation block */
563+
div[id^='src'] .l-hide, div[id^='src'] .hl-hide, .blame-hidden { /* hidden line number/annotation block */
564564
display: none
565565
}
566566

567-
#src .l, #src .hl, .blame .r, .blame .a,
567+
div[id^='src'] .l, div[id^='src'] .hl, .blame .r, .blame .a,
568568
#results .l, #more .l,
569569
#difftable i, del.d { /* line number/annotation block */
570570
display: inline-block;
@@ -577,12 +577,12 @@ table#dirlist { /* the "Name" column */
577577
color: #888;
578578
}
579579

580-
#src .hl { /* highlighted line number */
580+
div[id^='src'] .hl { /* highlighted line number */
581581
color: #000;
582582
}
583583

584584
/* highlight line number with anchor */
585-
#src a.l:target, #src a.hl:target {
585+
div[id^='src'] a.l:target, div[id^='src'] a.hl:target {
586586
background: orange;
587587
color:yellow;
588588
}
@@ -596,12 +596,12 @@ table#dirlist { /* the "Name" column */
596596
}
597597

598598
/* source code highlighting - see org/opengrok/analysis/$lang/*Xref.lex */
599-
#src .n { /* numbers/label */ color: #a52a2a; }
600-
#src .s { /* strings */ color: green; }
601-
#src .c { /* comment */ color: #666; }
602-
#src .b { /* heading/title/bold */ color: #000; font-weight: bold; }
603-
#src .k { /* block display */ color: #000; font-family: monospace; }
604-
#src a.d { /* symbol definition */ color: #909; font-weight: bold; }
599+
div[id^='src'] .n { /* numbers/label */ color: #a52a2a; }
600+
div[id^='src'] .s { /* strings */ color: green; }
601+
div[id^='src'] .c { /* comment */ color: #666; }
602+
div[id^='src'] .b { /* heading/title/bold */ color: #000; font-weight: bold; }
603+
div[id^='src'] .k { /* block display */ color: #000; font-family: monospace; }
604+
div[id^='src'] a.d { /* symbol definition */ color: #909; font-weight: bold; }
605605

606606
a.xm { /* macro */ color: #c66; font-weight: bold; }
607607
a.xa { /* argument */ color: #60c; font-weight: bold; }
@@ -704,7 +704,7 @@ a.xsr { /* subroutine */ color: #00f; font-weight: bold; }
704704
}
705705

706706
#results .con .all {
707-
margin-left: 6ex; /* width(#src .l) + 1ex */
707+
margin-left: 6ex; /* width(div[id^='src'] .l) + 1ex */
708708
}
709709

710710
#results .s, #more .s { /* matched line contents */

0 commit comments

Comments
 (0)