~royniang/lib

89d738474aeabf2ae89fd09518811779b1819948 — roy niang 9 months ago a48e869
Added more scripts. Added samterm patches.
A bin/facesstart => bin/facesstart +4 -0
@@ 0,0 1,4 @@
#!/bin/rc

facesgreet='[Arriving Messages]'
window 0,204,400,306 faces -c -m /mail/fs/Inbox -m /mail/fs/9 -m /mail/fs/OpenBSD -m /mail/fs/Gemini -m /mail/fs/Miscs-Lists -m /mail/fs/Feed

A bin/riostart => bin/riostart +7 -0
@@ 0,0 1,7 @@
#!/bin/rc

window -hide -scroll cat /dev/kprint
window -scroll


~ $console 0 || window -scroll -hide console

A bin/roi => bin/roi +7 -0
@@ 0,0 1,7 @@
#!/bin/rc

facesstart
todostart
statsstart
nailstart
window riow

A bin/s => bin/s +4 -0
@@ 0,0 1,4 @@
#!/bin/rc

bind /bin/aux/samterm.$sysname /bin/aux/samterm
font=$monospaced sam -a $*

A bin/statsstart => bin/statsstart +5 -0
@@ 0,0 1,5 @@
#!/bin/rc

facesgreet='[Buffered Tasks]'
font=$monospaced
window 0,0,400,204 stats -l8zmfe XOK9 Chitatap.$domain Asinru.$domain

A bin/todostart => bin/todostart +4 -0
@@ 0,0 1,4 @@
#!/bin/rc

facesgreet='[Buffered Tasks]'
window 0,306,400,408 faces -c -im /mail/fs/Later

A patches/samterm.XOK9.diff => patches/samterm.XOK9.diff +96 -0
@@ 0,0 1,96 @@
diff -r 175f3e344edd sys/src/cmd/samterm/flayer.c
--- a/sys/src/cmd/samterm/flayer.c	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/flayer.c	Sat Feb 20 13:42:52 2021 +0100
@@ -29,18 +29,22 @@
 	lDrect = r;
 
 	/* Main text is yellowish */
-	maincols[BACK] = allocimagemix(display, DPaleyellow, DWhite);
-	maincols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, DDarkyellow);
-	maincols[BORD] = allocimage(display, Rect(0,0,2,2), screen->chan, 1, DYellowgreen);
-	maincols[TEXT] = display->black;
-	maincols[HTEXT] = display->black;
+	maincols[BACK] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE2E8E8FF);
+	maincols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xCD664DFF);
+ 	maincols[BORD] = allocimage(display, Rect(0,0,2,2), CMAP8, 1, 0x8795BFFF);
+ 	draw(maincols[BORD], Rect(1,1,2,2), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE2E8E8FF), nil, ZP);
+ 	draw(maincols[BORD], Rect(0,0,1,1), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE2E8E8FF), nil, ZP);
+	maincols[TEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0x4F5165FF);
+	maincols[HTEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE2E8E8FF);
 
 	/* Command text is blueish */
-	cmdcols[BACK] = allocimagemix(display, DPalebluegreen, DWhite);
-	cmdcols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, DPalegreygreen);
-	cmdcols[BORD] = allocimage(display, Rect(0,0,2,2), screen->chan, 1, DPurpleblue);
-	cmdcols[TEXT] = display->black;
-	cmdcols[HTEXT] = display->black;
+	cmdcols[BACK] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0x4F5165FF);
+	cmdcols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE2E8E8FF);
+	cmdcols[BORD] = allocimage(display, Rect(0,0,2,2), CMAP8, 1, 0x8795BFFF);
+ 	draw(cmdcols[BORD], Rect(1,1,2,2), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE2E8E8FF), nil, ZP);
+ 	draw(cmdcols[BORD], Rect(0,0,1,1), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE2E8E8FF), nil, ZP);
+	cmdcols[TEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE2E8E8FF);
+	cmdcols[HTEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xCD664DFF);
 }
 
 void
diff -r 175f3e344edd sys/src/cmd/samterm/menu.c
--- a/sys/src/cmd/samterm/menu.c	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/menu.c	Sat Feb 20 13:42:52 2021 +0100
@@ -45,21 +45,21 @@
 };
 
 char	*menu2str[] = {
-	"cut",
-	"paste",
-	"snarf",
-	"plumb",
-	"look",
+	"Cut",
+	"Paste",
+	"Snarf",
+	"Plumb",
+	"Look",
 	"<rio>",
 	0,		/* storage for last pattern */
 };
 
 char	*menu3str[] = {
-	"new",
-	"zerox",
-	"resize",
-	"close",
-	"write",
+	"New",
+	"Zerox",
+	"Resize",
+	"Close",
+	"Write",
 };
 
 Menu	menu2 =	{0, genmenu2};
diff -r 175f3e344edd sys/src/cmd/samterm/mkfile
--- a/sys/src/cmd/samterm/mkfile	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/mkfile	Sat Feb 20 13:42:52 2021 +0100
@@ -1,6 +1,6 @@
 </$objtype/mkfile
 
-TARG=samterm
+TARG=samterm.$sysname
 OFILES=main.$O\
 	icons.$O\
 	menu.$O\
diff -r 175f3e344edd sys/src/cmd/samterm/scroll.c
--- a/sys/src/cmd/samterm/scroll.c	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/scroll.c	Sat Feb 20 13:42:52 2021 +0100
@@ -93,8 +93,9 @@
 	if(!eqrect(r2, l->lastsr)){
 		l->lastsr = r2;
 		draw(b, r1, l->f.cols[BORD], nil, ZP);
-		draw(b, r2, l->f.cols[BACK], nil, r2.min);
+		draw(b, r2, allocimage(display, Rect(0,0,2,2), screen->chan, 1, 0x8795BFFF), nil, r2.min);
 		r2 = r1;
+		r2.max.x = r2.max.x+1;
 		r2.min.x = r2.max.x-1;
 		draw(b, r2, l->f.cols[BORD], nil, ZP);
 		if(b!=l->f.b)

A patches/samterm.asinru.diff => patches/samterm.asinru.diff +96 -0
@@ 0,0 1,96 @@
diff -r 175f3e344edd sys/src/cmd/samterm/flayer.c
--- a/sys/src/cmd/samterm/flayer.c	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/flayer.c	Sat Feb 20 13:42:52 2021 +0100
@@ -29,18 +29,22 @@
 	lDrect = r;
 
 	/* Main text is yellowish */
-	maincols[BACK] = allocimagemix(display, DPaleyellow, DWhite);
-	maincols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, DDarkyellow);
-	maincols[BORD] = allocimage(display, Rect(0,0,2,2), screen->chan, 1, DYellowgreen);
-	maincols[TEXT] = display->black;
-	maincols[HTEXT] = display->black;
+	maincols[BACK] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xDBEBE2FF);
+	maincols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xCD664DFF);
+ 	maincols[BORD] = allocimage(display, Rect(0,0,2,2), CMAP8, 1, 0x75A07FFF);
+ 	draw(maincols[BORD], Rect(1,1,2,2), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xDBEBE2FF), nil, ZP);
+ 	draw(maincols[BORD], Rect(0,0,1,1), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xDBEBE2FF), nil, ZP);
+	maincols[TEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0x4B544EFF);
+	maincols[HTEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xDBEBE2FF);
 
 	/* Command text is blueish */
-	cmdcols[BACK] = allocimagemix(display, DPalebluegreen, DWhite);
-	cmdcols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, DPalegreygreen);
-	cmdcols[BORD] = allocimage(display, Rect(0,0,2,2), screen->chan, 1, DPurpleblue);
-	cmdcols[TEXT] = display->black;
-	cmdcols[HTEXT] = display->black;
+	cmdcols[BACK] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0x4B544EFF);
+	cmdcols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xDBEBE2FF);
+	cmdcols[BORD] = allocimage(display, Rect(0,0,2,2), CMAP8, 1, 0x75A07FFF);
+ 	draw(cmdcols[BORD], Rect(1,1,2,2), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xDBEBE2FF), nil, ZP);
+ 	draw(cmdcols[BORD], Rect(0,0,1,1), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xDBEBE2FF), nil, ZP);
+	cmdcols[TEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xDBEBE2FF);
+	cmdcols[HTEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xCD664DFF);
 }
 
 void
diff -r 175f3e344edd sys/src/cmd/samterm/menu.c
--- a/sys/src/cmd/samterm/menu.c	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/menu.c	Sat Feb 20 13:42:52 2021 +0100
@@ -45,21 +45,21 @@
 };
 
 char	*menu2str[] = {
-	"cut",
-	"paste",
-	"snarf",
-	"plumb",
-	"look",
+	"Cut",
+	"Paste",
+	"Snarf",
+	"Plumb",
+	"Look",
 	"<rio>",
 	0,		/* storage for last pattern */
 };
 
 char	*menu3str[] = {
-	"new",
-	"zerox",
-	"resize",
-	"close",
-	"write",
+	"New",
+	"Zerox",
+	"Resize",
+	"Close",
+	"Write",
 };
 
 Menu	menu2 =	{0, genmenu2};
diff -r 175f3e344edd sys/src/cmd/samterm/mkfile
--- a/sys/src/cmd/samterm/mkfile	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/mkfile	Sat Feb 20 13:42:52 2021 +0100
@@ -1,6 +1,6 @@
 </$objtype/mkfile
 
-TARG=samterm
+TARG=samterm.$sysname
 OFILES=main.$O\
 	icons.$O\
 	menu.$O\
diff -r 175f3e344edd sys/src/cmd/samterm/scroll.c
--- a/sys/src/cmd/samterm/scroll.c	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/scroll.c	Sat Feb 20 13:42:52 2021 +0100
@@ -93,8 +93,9 @@
 	if(!eqrect(r2, l->lastsr)){
 		l->lastsr = r2;
 		draw(b, r1, l->f.cols[BORD], nil, ZP);
-		draw(b, r2, l->f.cols[BACK], nil, r2.min);
+		draw(b, r2, allocimage(display, Rect(0,0,2,2), screen->chan, 1, 0x75A07FFF), nil, r2.min);
 		r2 = r1;
+		r2.max.x = r2.max.x+1;
 		r2.min.x = r2.max.x-1;
 		draw(b, r2, l->f.cols[BORD], nil, ZP);
 		if(b!=l->f.b)

A patches/samterm.chitatap.diff => patches/samterm.chitatap.diff +96 -0
@@ 0,0 1,96 @@
diff -r 175f3e344edd sys/src/cmd/samterm/flayer.c
--- a/sys/src/cmd/samterm/flayer.c	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/flayer.c	Sat Feb 20 13:42:52 2021 +0100
@@ -29,18 +29,22 @@
 	lDrect = r;
 
 	/* Main text is yellowish */
-	maincols[BACK] = allocimagemix(display, DPaleyellow, DWhite);
-	maincols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, DDarkyellow);
-	maincols[BORD] = allocimage(display, Rect(0,0,2,2), screen->chan, 1, DYellowgreen);
-	maincols[TEXT] = display->black;
-	maincols[HTEXT] = display->black;
+	maincols[BACK] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE8E7E6FF);
+	maincols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xCD664DFF);
+ 	maincols[BORD] = allocimage(display, Rect(0,0,2,2), CMAP8, 1, 0xA79375FF);
+ 	draw(maincols[BORD], Rect(1,1,2,2), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE8E7E6FF), nil, ZP);
+ 	draw(maincols[BORD], Rect(0,0,1,1), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE8E7E6FF), nil, ZP);
+	maincols[TEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0x54524BFF);
+	maincols[HTEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE8E7E6FF);
 
 	/* Command text is blueish */
-	cmdcols[BACK] = allocimagemix(display, DPalebluegreen, DWhite);
-	cmdcols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, DPalegreygreen);
-	cmdcols[BORD] = allocimage(display, Rect(0,0,2,2), screen->chan, 1, DPurpleblue);
-	cmdcols[TEXT] = display->black;
-	cmdcols[HTEXT] = display->black;
+	cmdcols[BACK] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0x54524BFF);
+	cmdcols[HIGH] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE8E7E6FF);
+	cmdcols[BORD] = allocimage(display, Rect(0,0,2,2), CMAP8, 1, 0xA79375FF);
+ 	draw(cmdcols[BORD], Rect(1,1,2,2), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE8E7E6FF), nil, ZP);
+ 	draw(cmdcols[BORD], Rect(0,0,1,1), allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE8E7E6FF), nil, ZP);
+	cmdcols[TEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xE8E7E6FF);
+	cmdcols[HTEXT] = allocimage(display, Rect(0,0,1,1), screen->chan, 1, 0xCD664DFF);
 }
 
 void
diff -r 175f3e344edd sys/src/cmd/samterm/menu.c
--- a/sys/src/cmd/samterm/menu.c	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/menu.c	Sat Feb 20 13:42:52 2021 +0100
@@ -45,21 +45,21 @@
 };
 
 char	*menu2str[] = {
-	"cut",
-	"paste",
-	"snarf",
-	"plumb",
-	"look",
+	"Cut",
+	"Paste",
+	"Snarf",
+	"Plumb",
+	"Look",
 	"<rio>",
 	0,		/* storage for last pattern */
 };
 
 char	*menu3str[] = {
-	"new",
-	"zerox",
-	"resize",
-	"close",
-	"write",
+	"New",
+	"Zerox",
+	"Resize",
+	"Close",
+	"Write",
 };
 
 Menu	menu2 =	{0, genmenu2};
diff -r 175f3e344edd sys/src/cmd/samterm/mkfile
--- a/sys/src/cmd/samterm/mkfile	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/mkfile	Sat Feb 20 13:42:52 2021 +0100
@@ -1,6 +1,6 @@
 </$objtype/mkfile
 
-TARG=samterm
+TARG=samterm.$sysname
 OFILES=main.$O\
 	icons.$O\
 	menu.$O\
diff -r 175f3e344edd sys/src/cmd/samterm/scroll.c
--- a/sys/src/cmd/samterm/scroll.c	Sat Feb 20 12:55:42 2021 +0100
+++ b/sys/src/cmd/samterm/scroll.c	Sat Feb 20 13:42:52 2021 +0100
@@ -93,8 +93,9 @@
 	if(!eqrect(r2, l->lastsr)){
 		l->lastsr = r2;
 		draw(b, r1, l->f.cols[BORD], nil, ZP);
-		draw(b, r2, l->f.cols[BACK], nil, r2.min);
+		draw(b, r2, allocimage(display, Rect(0,0,2,2), screen->chan, 1, 0xA79375FF), nil, r2.min);
 		r2 = r1;
+		r2.max.x = r2.max.x+1;
 		r2.min.x = r2.max.x-1;
 		draw(b, r2, l->f.cols[BORD], nil, ZP);
 		if(b!=l->f.b)