Fossil SCM

Lines now go directly from directories to child nodes, do not pass go, do not collect $200.

joel 2014-01-06 02:36 UTC csstree
Commit f83e0d21235d325e766576714408e413c6060e1f
2 files changed +4 -4 +43 -27
+4 -4
--- src/browse.c
+++ src/browse.c
@@ -544,20 +544,20 @@
544544
545545
546546
/* Generate a multi-column table listing the contents of zD[]
547547
** directory.
548548
*/
549
- @ <ul class="filetree root">
549
+ @ <div class="filetree"><ul>
550550
if( nD ){
551551
char *zLink = href("%s", url_render(&sURI, "name", 0, 0, 0));
552552
@ <li class="dir">
553553
@ %z(zLink)%h(zProjectName)</a>
554554
}else{
555555
@ <li class="dir subdir">
556556
@ <a>%h(zProjectName)</a>
557557
}
558
- @ <ul class="filetree">
558
+ @ <ul>
559559
for(p=sTree.pFirst; p; p=p->pNext){
560560
if( p->isDir ){
561561
if( nD && strlen(p->zFullName)==nD-1 ){
562562
@ <li class="dir subdir">
563563
}else{
@@ -567,11 +567,11 @@
567567
@ <a>%h(p->zName)</a>
568568
}else{
569569
char *zLink = href("%s", url_render(&sURI, "name", p->zFullName, 0, 0));
570570
@ %z(zLink)%h(p->zName)</a>
571571
}
572
- @ <ul class="filetree">
572
+ @ <ul>
573573
}else{
574574
char *zLink;
575575
if( zCI ){
576576
zLink = href("%R/artifact/%s",p->zUuid);
577577
}else{
@@ -585,11 +585,11 @@
585585
@ </ul>
586586
}
587587
}
588588
}
589589
@ </ul>
590
- @ </ul>
590
+ @ </ul></div>
591591
style_footer();
592592
593593
/* We could free memory used by sTree here if we needed to. But
594594
** the process is about to exit, so doing so would not really accomplish
595595
** anything useful. */
596596
--- src/browse.c
+++ src/browse.c
@@ -544,20 +544,20 @@
544
545
546 /* Generate a multi-column table listing the contents of zD[]
547 ** directory.
548 */
549 @ <ul class="filetree root">
550 if( nD ){
551 char *zLink = href("%s", url_render(&sURI, "name", 0, 0, 0));
552 @ <li class="dir">
553 @ %z(zLink)%h(zProjectName)</a>
554 }else{
555 @ <li class="dir subdir">
556 @ <a>%h(zProjectName)</a>
557 }
558 @ <ul class="filetree">
559 for(p=sTree.pFirst; p; p=p->pNext){
560 if( p->isDir ){
561 if( nD && strlen(p->zFullName)==nD-1 ){
562 @ <li class="dir subdir">
563 }else{
@@ -567,11 +567,11 @@
567 @ <a>%h(p->zName)</a>
568 }else{
569 char *zLink = href("%s", url_render(&sURI, "name", p->zFullName, 0, 0));
570 @ %z(zLink)%h(p->zName)</a>
571 }
572 @ <ul class="filetree">
573 }else{
574 char *zLink;
575 if( zCI ){
576 zLink = href("%R/artifact/%s",p->zUuid);
577 }else{
@@ -585,11 +585,11 @@
585 @ </ul>
586 }
587 }
588 }
589 @ </ul>
590 @ </ul>
591 style_footer();
592
593 /* We could free memory used by sTree here if we needed to. But
594 ** the process is about to exit, so doing so would not really accomplish
595 ** anything useful. */
596
--- src/browse.c
+++ src/browse.c
@@ -544,20 +544,20 @@
544
545
546 /* Generate a multi-column table listing the contents of zD[]
547 ** directory.
548 */
549 @ <div class="filetree"><ul>
550 if( nD ){
551 char *zLink = href("%s", url_render(&sURI, "name", 0, 0, 0));
552 @ <li class="dir">
553 @ %z(zLink)%h(zProjectName)</a>
554 }else{
555 @ <li class="dir subdir">
556 @ <a>%h(zProjectName)</a>
557 }
558 @ <ul>
559 for(p=sTree.pFirst; p; p=p->pNext){
560 if( p->isDir ){
561 if( nD && strlen(p->zFullName)==nD-1 ){
562 @ <li class="dir subdir">
563 }else{
@@ -567,11 +567,11 @@
567 @ <a>%h(p->zName)</a>
568 }else{
569 char *zLink = href("%s", url_render(&sURI, "name", p->zFullName, 0, 0));
570 @ %z(zLink)%h(p->zName)</a>
571 }
572 @ <ul>
573 }else{
574 char *zLink;
575 if( zCI ){
576 zLink = href("%R/artifact/%s",p->zUuid);
577 }else{
@@ -585,11 +585,11 @@
585 @ </ul>
586 }
587 }
588 }
589 @ </ul>
590 @ </ul></div>
591 style_footer();
592
593 /* We could free memory used by sTree here if we needed to. But
594 ** the process is about to exit, so doing so would not really accomplish
595 ** anything useful. */
596
+43 -27
--- src/style.c
+++ src/style.c
@@ -772,61 +772,77 @@
772772
@ margin-left: 0.5em;
773773
@ padding-left: 0.5em;
774774
@ white-space: nowrap;
775775
},
776776
{ ".filetree",
777
- "file tree root and branch lists",
777
+ "",
778
+ @ margin: 1em 0;
779
+ @ line-height: 1.5;
780
+ },
781
+ { ".filetree ul",
782
+ "file tree lists",
778783
@ display: inline;
784
+ @ margin: 0;
779785
@ padding: 0;
780786
},
781
- { ".filetree.root",
782
- "file tree root",
783
- @ display: block;
784
- @ list-style: none;
785
- },
786787
{ ".filetree li",
787788
"file tree list items",
788789
@ display: inline;
789790
},
790791
{ ".filetree .subdir ul",
791792
"file tree lists below subdir",
793
+ @ position: relative;
792794
@ display: block;
793
- @ margin: 0 0 .5em 7px;
794
- @ padding: .2em 0 0 12px;
795
- @ border-left: 2px solid #ccc;
795
+ @ margin: 0 0 0 21px;
796
+ @ padding: 0;
796797
},
797798
{ ".filetree .subdir li",
798799
"file tree lists items below subdir",
799800
@ position: relative;
800801
@ display: block;
801
- @ margin: .2em 0;
802
+ @ margin: 0;
802803
@ padding: 0;
803804
},
804805
{ ".filetree .subdir li:before",
805
- "file tree horizontal lines connecting children to parent",
806
+ "file tree node lines",
807
+ @ content: '';
808
+ @ position: absolute;
809
+ @ top: -.8em;
810
+ @ left: -14px;
811
+ @ width: 14px;
812
+ @ height: 1.5em;
813
+ @ border-left: 2px solid #aaa;
814
+ @ border-bottom: 2px solid #aaa;
815
+ },
816
+ { ".filetree .subdir > ul ul:before",
817
+ "file tree directory lines",
806818
@ content: '';
807819
@ position: absolute;
808
- @ top: .5em;
809
- @ left: -12px;
810
- @ margin-top: 1px;
811
- @ width: 10px;
812
- @ border-top: 2px solid #ccc;
820
+ @ top: -1.5em;
821
+ @ bottom: 0;
822
+ @ left: -35px;
823
+ @ border-left: 2px solid #aaa;
824
+ },
825
+ { ".filetree .subdir li:last-child > ul:before",
826
+ "",
827
+ @ display: none;
813828
},
814829
{ ".filetree a",
815830
"file tree links",
831
+ @ position: relative;
832
+ @ z-index: 1;
833
+ @ display: inline-block;
834
+ @ min-height: 16px;
816835
@ margin-right: .5em;
817
- },
818
- { ".filetree a:before",
819
- "file tree link icons",
820
- @ margin-right: 5px;
821
- @ line-height: 0;
822
- @ vertical-align: -3px;
823
- @ content: url(data:image/gif;base64,R0lGODlhEAAQAJEAAP\/\/\/yEhIf\/\/\/wAAACH5BAEHAAIALAAAAAAQABAAAAIvlIKpxqcfmgOUvoaqDSCxrEEfF14GqFXImJZsu73wepJzVMNxrtNTj3NATMKhpwAAOw==);
824
- },
825
- { ".filetree .dir > a:before",
826
- "file tree directory link icons",
827
- @ content: url(data:image/gif;base64,R0lGODlhEAAQAJEAAP/WVCIiIv\/\/\/wAAACH5BAEHAAIALAAAAAAQABAAAAInlI9pwa3XYniCgQtkrAFfLXkiFo1jaXpo+jUs6b5Z/K4siDu5RPUFADs=);
836
+ @ padding-left: 21px;
837
+ @ background-image: url(data:image/gif;base64,R0lGODlhEAAQAJEAAP\/\/\/yEhIf\/\/\/wAAACH5BAEHAAIALAAAAAAQABAAAAIvlIKpxqcfmgOUvoaqDSCxrEEfF14GqFXImJZsu73wepJzVMNxrtNTj3NATMKhpwAAOw==);
838
+ @ background-position: center left;
839
+ @ background-repeat: no-repeat;
840
+ },
841
+ { ".filetree .dir > a",
842
+ "file tree directory link",
843
+ @ background-image: url(data:image/gif;base64,R0lGODlhEAAQAJEAAP/WVCIiIv\/\/\/wAAACH5BAEHAAIALAAAAAAQABAAAAInlI9pwa3XYniCgQtkrAFfLXkiFo1jaXpo+jUs6b5Z/K4siDu5RPUFADs=);
828844
},
829845
{ "table.login_out",
830846
"table format for login/out label/input table",
831847
@ text-align: left;
832848
@ margin-right: 10px;
833849
--- src/style.c
+++ src/style.c
@@ -772,61 +772,77 @@
772 @ margin-left: 0.5em;
773 @ padding-left: 0.5em;
774 @ white-space: nowrap;
775 },
776 { ".filetree",
777 "file tree root and branch lists",
 
 
 
 
 
778 @ display: inline;
 
779 @ padding: 0;
780 },
781 { ".filetree.root",
782 "file tree root",
783 @ display: block;
784 @ list-style: none;
785 },
786 { ".filetree li",
787 "file tree list items",
788 @ display: inline;
789 },
790 { ".filetree .subdir ul",
791 "file tree lists below subdir",
 
792 @ display: block;
793 @ margin: 0 0 .5em 7px;
794 @ padding: .2em 0 0 12px;
795 @ border-left: 2px solid #ccc;
796 },
797 { ".filetree .subdir li",
798 "file tree lists items below subdir",
799 @ position: relative;
800 @ display: block;
801 @ margin: .2em 0;
802 @ padding: 0;
803 },
804 { ".filetree .subdir li:before",
805 "file tree horizontal lines connecting children to parent",
 
 
 
 
 
 
 
 
 
 
 
806 @ content: '';
807 @ position: absolute;
808 @ top: .5em;
809 @ left: -12px;
810 @ margin-top: 1px;
811 @ width: 10px;
812 @ border-top: 2px solid #ccc;
 
 
 
813 },
814 { ".filetree a",
815 "file tree links",
 
 
 
 
816 @ margin-right: .5em;
817 },
818 { ".filetree a:before",
819 "file tree link icons",
820 @ margin-right: 5px;
821 @ line-height: 0;
822 @ vertical-align: -3px;
823 @ content: url(data:image/gif;base64,R0lGODlhEAAQAJEAAP\/\/\/yEhIf\/\/\/wAAACH5BAEHAAIALAAAAAAQABAAAAIvlIKpxqcfmgOUvoaqDSCxrEEfF14GqFXImJZsu73wepJzVMNxrtNTj3NATMKhpwAAOw==);
824 },
825 { ".filetree .dir > a:before",
826 "file tree directory link icons",
827 @ content: url(data:image/gif;base64,R0lGODlhEAAQAJEAAP/WVCIiIv\/\/\/wAAACH5BAEHAAIALAAAAAAQABAAAAInlI9pwa3XYniCgQtkrAFfLXkiFo1jaXpo+jUs6b5Z/K4siDu5RPUFADs=);
828 },
829 { "table.login_out",
830 "table format for login/out label/input table",
831 @ text-align: left;
832 @ margin-right: 10px;
833
--- src/style.c
+++ src/style.c
@@ -772,61 +772,77 @@
772 @ margin-left: 0.5em;
773 @ padding-left: 0.5em;
774 @ white-space: nowrap;
775 },
776 { ".filetree",
777 "",
778 @ margin: 1em 0;
779 @ line-height: 1.5;
780 },
781 { ".filetree ul",
782 "file tree lists",
783 @ display: inline;
784 @ margin: 0;
785 @ padding: 0;
786 },
 
 
 
 
 
787 { ".filetree li",
788 "file tree list items",
789 @ display: inline;
790 },
791 { ".filetree .subdir ul",
792 "file tree lists below subdir",
793 @ position: relative;
794 @ display: block;
795 @ margin: 0 0 0 21px;
796 @ padding: 0;
 
797 },
798 { ".filetree .subdir li",
799 "file tree lists items below subdir",
800 @ position: relative;
801 @ display: block;
802 @ margin: 0;
803 @ padding: 0;
804 },
805 { ".filetree .subdir li:before",
806 "file tree node lines",
807 @ content: '';
808 @ position: absolute;
809 @ top: -.8em;
810 @ left: -14px;
811 @ width: 14px;
812 @ height: 1.5em;
813 @ border-left: 2px solid #aaa;
814 @ border-bottom: 2px solid #aaa;
815 },
816 { ".filetree .subdir > ul ul:before",
817 "file tree directory lines",
818 @ content: '';
819 @ position: absolute;
820 @ top: -1.5em;
821 @ bottom: 0;
822 @ left: -35px;
823 @ border-left: 2px solid #aaa;
824 },
825 { ".filetree .subdir li:last-child > ul:before",
826 "",
827 @ display: none;
828 },
829 { ".filetree a",
830 "file tree links",
831 @ position: relative;
832 @ z-index: 1;
833 @ display: inline-block;
834 @ min-height: 16px;
835 @ margin-right: .5em;
836 @ padding-left: 21px;
837 @ background-image: url(data:image/gif;base64,R0lGODlhEAAQAJEAAP\/\/\/yEhIf\/\/\/wAAACH5BAEHAAIALAAAAAAQABAAAAIvlIKpxqcfmgOUvoaqDSCxrEEfF14GqFXImJZsu73wepJzVMNxrtNTj3NATMKhpwAAOw==);
838 @ background-position: center left;
839 @ background-repeat: no-repeat;
840 },
841 { ".filetree .dir > a",
842 "file tree directory link",
843 @ background-image: url(data:image/gif;base64,R0lGODlhEAAQAJEAAP/WVCIiIv\/\/\/wAAACH5BAEHAAIALAAAAAAQABAAAAInlI9pwa3XYniCgQtkrAFfLXkiFo1jaXpo+jUs6b5Z/K4siDu5RPUFADs=);
 
 
 
844 },
845 { "table.login_out",
846 "table format for login/out label/input table",
847 @ text-align: left;
848 @ margin-right: 10px;
849

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button