summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2015-09-22 11:49:07 +0200
committercinap_lenrek <cinap_lenrek@felloff.net>2015-09-22 11:49:07 +0200
commit83d45ee5025546b99d2ccd8491c808eb50f3bad9 (patch)
treec5e2e44c2de818d14148033617f1ef2264b1d6d5 /sys
parent95cfc307881d044b0fddd6abf9c0b6b65e780832 (diff)
mothra: <hr> drawing
<hr> is handled by drawing replicated bitmap across the with of the page.
Diffstat (limited to 'sys')
-rw-r--r--sys/src/cmd/mothra/libpanel/rtext.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/src/cmd/mothra/libpanel/rtext.c b/sys/src/cmd/mothra/libpanel/rtext.c
index 8f8fe4704..88495f2af 100644
--- a/sys/src/cmd/mothra/libpanel/rtext.c
+++ b/sys/src/cmd/mothra/libpanel/rtext.c
@@ -88,7 +88,7 @@ Point pl_rtfmt(Rtext *t, int wid){
if(tp->b){
a=tp->b->r.max.y-tp->b->r.min.y+BORD;
d=BORD;
- w=tp->b->r.max.x-tp->b->r.min.x+BORD*2;
+ w=tp->b->repl?wid-x:tp->b->r.max.x-tp->b->r.min.x+BORD*2;
}
else if(tp->p){
/* what if plpack fails? */
@@ -134,7 +134,7 @@ Point pl_rtfmt(Rtext *t, int wid){
if(t->b){
t->r.max.y=p.y+BORD;
t->r.min.y=p.y-(t->b->r.max.y-t->b->r.min.y)-BORD;
- p.x+=(t->b->r.max.x-t->b->r.min.x)+BORD*2;
+ p.x+=t->b->repl?wid-p.x:(t->b->r.max.x-t->b->r.min.x)+BORD*2;
}
else if(t->p){
t->r.max.y=p.y;