+#define _XOPEN_SOURCE 700
+#include <liba.h>
#include <stdc.h>
#include "dbc.h"
-#include "utf.h"
#include <ctype.h>
#include <unistd.h>
#include <fcntl.h>
int buf_getrat(Buf* buf, size_t off)
{
require(buf != NULL);
- size_t rlen = 0;
+ Int rlen = 0;
Rune rune = 0;
if (gapbuf_getb(&buf->contents, off) == '\r' && gapbuf_getb(&buf->contents, off+1) == '\n')
{
}
else
{
- while ( !utf8decode(&rune, &rlen, gapbuf_getb(&buf->contents, off++)) )
+ while ( !UTF8_Decode(&rune, &rlen, gapbuf_getb(&buf->contents, off++)) )
{
}
}
void buf_putc(Buf* buf, int c)
{
require(buf != NULL);
- char utf8buf[UTF_MAX+1] = {0};
- (void)utf8encode(utf8buf, c);
- buf_puts(buf, utf8buf);
+ Byte utf8buf[UTF_MAX+1] = {0};
+ (void)UTF8_Encode(utf8buf, c);
+ buf_puts(buf, (char*)utf8buf);
ensure(buf_valid(buf));
}
+#include <liba.h>
#include <stdc.h>
#include "dbc.h"
#include <stdio.h>
#include <signal.h>
-#include "io.h"
#ifndef NDEBUG
static void dump_and_abort(char* msg)
{
- telem_send("%s", msg);
+ Telemetry_Send("%s", msg);
FILE* f = (DumpPath ? fopen(DumpPath, "w") : stderr);
fprintf(f, "%s\n\n", msg);
if (DumpFn)
+#include <liba.h>
#include <stdc.h>
-#include "utf.h"
#include "tide.h"
#include "config.h"
+#include <liba.h>
#include <stdc.h>
#include "dbc.h"
-#include "utf.h"
#include "tide.h"
#include "config.h"
+#define _XOPEN_SOURCE 700
+#include <liba.h>
#include <stdc.h>
-#include "utf.h"
#include "dbc.h"
#include "tide.h"
#include <stdc.h>
#include "dbc.h"
-//#include "utf.h"
-//#include <ctype.h>
#include <unistd.h>
-//#include <fcntl.h>
-//#include <sys/stat.h>
#include <dirent.h>
#include <vec.h>
require(buf != NULL);
File fd;
long nwrite = 0;
-// if (path && (fd = open(path, O_WRONLY|O_CREAT|O_TRUNC, 0644)) >= 0)
if (path && (fd = File_OpenForWrite(path)) >= 0)
{
nwrite = File_Write(fd, buf->bufstart, (buf->gapstart - buf->bufstart));
+++ /dev/null
-/**
- @file
- Helper functions for reading and writing file descriptors as well as outputting telemetry data.
-*/
-void telem_send(char* fmt, ...);
-
-//long writefd(int fd, char* data, long towrite);
-//long readfd(int fd, char* data, long toread);
-//char* readfile(char* path);
-
-char* abspath(char* path);
#define _XOPEN_SOURCE 700
#include <liba.h>
-
#include <stdc.h>
-#include "io.h"
#include <unistd.h>
#include <sys/wait.h>
#include <sys/socket.h>
char buffer[32769];
errno = 0;
long nread = read(job->fd, buffer, sizeof(buffer)-1);
- telem_send("PIPE_READ(fd : %d, ret: %ld)\n", job->fd, nread);
+ Telemetry_Send("PIPE_READ(fd : %d, ret: %ld)\n", job->fd, nread);
if (nread <= 0)
{
job->readfn = NULL;
while (job && job->fd != fd)
job = job->next;
if (!job || !events) return;
- telem_send("JOB(fd: %d, events: 0x%x)\n", fd, events);
+ Telemetry_Send("JOB(fd: %d, events: 0x%x)\n", fd, events);
if (job->readfn && (events & (POLLIN|POLLHUP)))
{
- telem_send("JOB_READ(fd: %d)\n", job->fd);
+ Telemetry_Send("JOB_READ(fd: %d)\n", job->fd);
job->readfn(job);
}
if (job->writefn && (events & POLLOUT))
{
- telem_send("JOB_WRITE(fd: %d)\n", job->fd);
+ Telemetry_Send("JOB_WRITE(fd: %d)\n", job->fd);
job->writefn(job);
}
if ((events & POLLERR) || (!job->readfn && !job->writefn))
{
- telem_send("JOB_FINISH(fd: %d)\n", job->fd);
+ Telemetry_Send("JOB_FINISH(fd: %d)\n", job->fd);
job_finish(job);
}
}
long ret = poll(JobFds, njobs, ms);
if (ret != 0)
{
- telem_send("POLL(njobs: %d, ms: %d, ret: %d)\n", njobs, ms, ret);
+ Telemetry_Send("POLL(njobs: %d, ms: %d, ret: %d)\n", njobs, ms, ret);
}
/* process all jobs with events reported */
+#include <liba.h>
#include <stdc.h>
-#include "utf.h"
#include "tide.h"
static void leap_process_keysym(LeapState_T* state, unsigned long keysym)
uint32_t key = x11_getkey(keysym);
if (key != RUNE_ERR)
{
- char utf8buf[UTF_MAX+1] = {0};
- size_t sz = utf8encode(utf8buf, key);
+ Byte utf8buf[UTF_MAX+1] = {0};
+ size_t sz = UTF8_Encode(utf8buf, key);
for (size_t i = 0; i < sz; i++)
{
state->buf[state->nbuf++] = utf8buf[i];
+#define _XOPEN_SOURCE 700
+#include <liba.h>
#include <stdc.h>
#include "dbc.h"
-#include "utf.h"
-#include "io.h"
#include <locale.h>
#include <sys/wait.h>
{
Focused = (e->xkey.y <= Divider ? TAGS : EDIT);
uint32_t key = x11_process_key(x, e, Bindings);
- telem_send("KEY(reg: %d, key: 0x%x)\n", Focused, key);
+ Telemetry_Send("KEY(reg: %d, key: 0x%x)\n", Focused, key);
if (key != RUNE_ERR)
{
view_insert(win_view(FOCUSED), key);
Focused = (e->xbutton.y <= Divider ? TAGS : EDIT);
get_position(Focused, e->xbutton.x, e->xbutton.y, &row, &col);
int action = process_mouse(e->xbutton.button, (e->type == ButtonPress));
- telem_send("BTNPRESS(reg: %d, btn: %d, press: %d, act: %d)\n",
+ Telemetry_Send("BTNPRESS(reg: %d, btn: %d, press: %d, act: %d)\n",
Focused, e->xbutton.button, (e->type == ButtonPress), action);
switch (action)
{
size_t row, col;
int xpos = ev->x, ypos = ev->y;
get_position(Focused, xpos, ypos, &row, &col);
- telem_send("BTNMOVE(reg: %d, btn: 0x%x, x: %d, y: %d, r: %d, c: %d)\n",
+ Telemetry_Send("BTNMOVE(reg: %d, btn: 0x%x, x: %d, y: %d, r: %d, c: %d)\n",
Focused, ev->state, xpos, ypos, row, col);
if (PRESSED(ev->state, MouseLeft))
view_setcursor(win_view(Focused), row, col, true);
size_t tagrows = view_limitrows(win_view(TAGS), maxtagrows);
size_t tagregsz = (tagrows * x->tagfont->height) + 7;
size_t editrows = (height - tagregsz) / x->font->height ;
- telem_send("REDRAW(tagrows: %d, editrows: %d)\n", tagrows, editrows);
+ Telemetry_Send("REDRAW(tagrows: %d, editrows: %d)\n", tagrows, editrows);
/* draw the regions to the window */
int olddiv = Divider;
if (buf_save(buf, arg) == NORMAL)
{
/* convert saved path to absolute path */
- char* path = abspath(buf->path);
+ char* path = File_AbsolutePath(buf->path);
buf_setpath(buf, path);
free(path);
}
static void edit_file(char* file, int line_num)
{
- file = abspath(file);
+ file = File_AbsolutePath(file);
if (!strcmp("-", file))
{
job_readfd(STDIN_FILENO, win_view(EDIT));
+#include <liba.h>
#include <stdc.h>
-#include "utf.h"
#include "dbc.h"
#include "tide.h"
+#include <liba.h>
#include <stdc.h>
-#include "utf.h"
#include "tide.h"
+#include <liba.h>
#include <stdc.h>
-#include "utf.h"
#include "tide.h"
+++ /dev/null
-/** @file */
-enum {
- UTF_MAX = 6u, /* maximum number of bytes that make up a rune */
- RUNE_SELF = 0x80, /* byte values larger than this are *not* ascii */
- RUNE_ERR = 0xFFFD, /* rune value representing an error */
- RUNE_MAX = 0x10FFFF, /* Maximum decodable rune value */
- RUNE_EOF = -1, /* rune value representing end of file */
-};
-
-/* Represents a unicode code point */
-typedef int32_t Rune;
-
-size_t utf8encode(char str[UTF_MAX], Rune rune);
-bool utf8decode(Rune* rune, size_t* length, int byte);
-int runewidth(unsigned col, Rune r);
-bool risword(Rune r);
-bool rissigil(Rune r);
-bool risfile(Rune r);
-bool riscmd(Rune r);
-bool risblank(Rune r);
-bool risbigword(Rune r);
+++ /dev/null
-#include <stdc.h>
-#include "utf.h"
-#include <wchar.h>
-#include <ctype.h>
-
-#include "config.h"
-
-static const uint8_t UTF8_SeqBits[] = { 0x00, 0x80, 0xC0, 0xE0, 0xF0, 0xF8, 0xFC, 0xFE };
-static const uint8_t UTF8_SeqMask[] = { 0x00, 0xFF, 0x1F, 0x0F, 0x07, 0x03, 0x01, 0x00 };
-static const uint8_t UTF8_SeqLens[] = { 0x01, 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, 0x00 };
-
-static bool runevalid(Rune val)
-{
- return (val <= RUNE_MAX)
- && ((val & 0xFFFE) != 0xFFFE)
- && ((val < 0xD800) || (val > 0xDFFF))
- && ((val < 0xFDD0) || (val > 0xFDEF));
-}
-
-static size_t runelen(Rune rune)
-{
- size_t ret;
- if(!runevalid(rune))
- {
- ret = 0;
- }
- else if(rune <= 0x7F)
- {
- ret = 1;
- }
- else if(rune <= 0x07FF)
- {
- ret = 2;
- }
- else if(rune <= 0xFFFF)
- {
- ret = 3;
- }
- else
- {
- ret = 4;
- }
- return ret;
-}
-
-static uint8_t utfseq(uint8_t byte)
-{
- uint8_t ret = 0;
- for (int i = 1; i < 8; i++)
- {
- if ((byte & UTF8_SeqBits[i]) == UTF8_SeqBits[i-1])
- {
- ret = UTF8_SeqLens[i-1];
- break;
- }
- }
- return ret;
-}
-
-size_t utf8encode(char str[UTF_MAX], Rune rune)
-{
- size_t len = runelen(rune);
- str[0] = (len == 1 ? 0x00 : UTF8_SeqBits[len])
- | (UTF8_SeqMask[len] & (rune >> (6 * (len-1))));
- for (size_t i = 1; i < len; i++)
- str[i] = 0x80u | (0x3Fu & (rune >> (6 * (len-i-1))));
- return len;
-}
-
-bool utf8decode(Rune* rune, size_t* length, int byte)
-{
- /* Handle the start of a new rune */
- if (*length == 0) {
- /* If we were fed in an EOF as a start byte, handle it here */
- if (byte == EOF) {
- *rune = RUNE_EOF;
- } else {
- /* Otherwise, decode the first byte of the rune */
- *length = utfseq(byte);
- *rune = (*length == 0) ? RUNE_ERR : (byte & UTF8_SeqMask[*length]);
- (*length)--;
- }
- /* Handle continuation bytes */
- } else if ((byte & 0xC0) == 0x80) {
- /* add bits from continuation byte to rune value
- * cannot overflow: 6 byte sequences contain 31 bits */
- *rune = (*rune << 6) | (byte & 0x3F); /* 10xxxxxx */
- (*length)--;
- /* Sanity check the final rune value before finishing */
- if ((*length == 0) && !runevalid(*rune))
- *rune = RUNE_ERR;
- /* Didn't get the continuation byte we expected */
- } else {
- *rune = RUNE_ERR;
- }
- /* Tell the caller whether we finished or not */
- return ((*length == 0) || (*rune == RUNE_ERR));
-}
-
-int runewidth(unsigned col, Rune r)
-{
- int width;
- if (r == '\t')
- {
- width = (TabWidth - (col % TabWidth));
- }
- else
- {
- width = wcwidth(r);
- if (width < 0) width = 1;
- }
- return width;
-}
-
-bool risword(Rune r)
-{
- return (r < 127 && (isalnum(r) || r == '_' || r == '+' || r == '-'));
-}
-
-bool rissigil(Rune r)
-{
- return (r == ':' || r == '!' || r == '&' || r == '|' || r == '>' || r == '<');
-}
-
-bool risfile(Rune r)
-{
- return (risword(r) || r == '/' || r == '.' || r == ':' || r == '-' || r == '~');
-}
-
-bool riscmd(Rune r)
-{
- return (risword(r) || rissigil(r));
-}
-
-bool risblank(Rune r)
-{
- return (r == ' ' || r == '\t' || r == '\n' || r == '\r');
-}
-
-bool risbigword(Rune r)
-{
- return !risblank(r);
-}
-
+#include <liba.h>
#include <stdc.h>
#include "dbc.h"
-#include "utf.h"
#include <ctype.h>
#include "tide.h"
+#include <liba.h>
#include <stdc.h>
#include "x11.h"
-#include "utf.h"
-#include "io.h"
#include <locale.h>
#include <signal.h>
#include <sys/types.h>
/* process the entire event queue */
while (XEventsQueued(x->display, QueuedAfterReading))
{
- telem_send("EV_READ_QUEUE(pending: %d)\n", XPending(x->display));
+ Telemetry_Send("EV_READ_QUEUE(pending: %d)\n", XPending(x->display));
XGetMotionEvents(x->display, x->self, CurrentTime, CurrentTime, &nevents);
for (XEvent e; XPending(x->display);)
update_state(x, &e);
if (!XFilterEvent(&e, None) && x->eventfns[e.type])
{
- telem_send("EV_HANDLE(type: %d)\n", e.type);
+ Telemetry_Send("EV_HANDLE(type: %d)\n", e.type);
(x->eventfns[e.type])(x, &e);
}
else
{
- telem_send("EV_IGNORE(type: %d)\n", e.type);
+ Telemetry_Send("EV_IGNORE(type: %d)\n", e.type);
}
/* log error here */
{
char msg[8192];
XGetErrorText(x->display, err->error_code, msg, sizeof(msg));
- telem_send("XERROR(%s)\n", msg);
+ Telemetry_Send("XERROR(%s)\n", msg);
x11_error_clear();
}
}
hints.flags &= ~XUrgencyHint;
}
status = XSetWMHints(x->display, x->self, &hints);
- telem_send("URGENT(%d %d)\n", urgent, status);
+ Telemetry_Send("URGENT(%d %d)\n", urgent, status);
return status;
}
+#include <liba.h>
#include <stdc.h>
#include "x11.h"
-#include "io.h"
#include <X11/extensions/Xinerama.h>
void x11_resize(XConf* x, XEvent* e)
{
- telem_send("XRESIZE(w: %d, h: %d)\n", e->xconfigure.width, e->xconfigure.height);
+ Telemetry_Send("XRESIZE(w: %d, h: %d)\n", e->xconfigure.width, e->xconfigure.height);
if (e->xconfigure.width != x->width || e->xconfigure.height != x->height)
{
x->width = e->xconfigure.width;
void x11_mapnotify(XConf* x, XEvent* e)
{
(void)x;
- telem_send("XMAPNOTIFY(0x%x)\n", e->xmap.window);
+ Telemetry_Send("XMAPNOTIFY(0x%x)\n", e->xmap.window);
}
void x11_enternotify(XConf* x, XEvent* e)
{
- telem_send("XENTERNOTIFY(0x%x)\n", e->xmap.window);
+ Telemetry_Send("XENTERNOTIFY(0x%x)\n", e->xmap.window);
x11_seturgent(x, 0);
}
#define _XOPEN_SOURCE 700
#include <liba.h>
#include <stdc.h>
-#include "io.h"
#include <sys/socket.h>
#ifdef __linux__
#include <pty.h>
+++ /dev/null
-/** @file */
-enum {
- UTF_MAX = 6u, /* maximum number of bytes that make up a rune */
- RUNE_SELF = 0x80, /* byte values larger than this are *not* ascii */
- RUNE_ERR = 0xFFFD, /* rune value representing an error */
- RUNE_MAX = 0x10FFFF, /* Maximum decodable rune value */
- RUNE_EOF = -1, /* rune value representing end of file */
-};
-
-/* Represents a unicode code point */
-typedef int32_t Rune;
-
-size_t utf8encode(char str[UTF_MAX], Rune rune);
-bool utf8decode(Rune* rune, size_t* length, int byte);
-int runewidth(unsigned col, Rune r);
-bool risword(Rune r);
-bool rissigil(Rune r);
-bool risfile(Rune r);
-bool riscmd(Rune r);
-bool risblank(Rune r);
-bool risbigword(Rune r);
+++ /dev/null
-#include <stdc.h>
-#include "utf.h"
-#include <wchar.h>
-#include <ctype.h>
-
-#include "config.h"
-
-static const uint8_t UTF8_SeqBits[] = { 0x00, 0x80, 0xC0, 0xE0, 0xF0, 0xF8, 0xFC, 0xFE };
-static const uint8_t UTF8_SeqMask[] = { 0x00, 0xFF, 0x1F, 0x0F, 0x07, 0x03, 0x01, 0x00 };
-static const uint8_t UTF8_SeqLens[] = { 0x01, 0x00, 0x02, 0x03, 0x04, 0x05, 0x06, 0x00 };
-
-static bool runevalid(Rune val)
-{
- return (val <= RUNE_MAX)
- && ((val & 0xFFFE) != 0xFFFE)
- && ((val < 0xD800) || (val > 0xDFFF))
- && ((val < 0xFDD0) || (val > 0xFDEF));
-}
-
-static size_t runelen(Rune rune)
-{
- size_t ret;
- if(!runevalid(rune))
- {
- ret = 0;
- }
- else if(rune <= 0x7F)
- {
- ret = 1;
- }
- else if(rune <= 0x07FF)
- {
- ret = 2;
- }
- else if(rune <= 0xFFFF)
- {
- ret = 3;
- }
- else
- {
- ret = 4;
- }
- return ret;
-}
-
-static uint8_t utfseq(uint8_t byte)
-{
- uint8_t ret = 0;
- for (int i = 1; i < 8; i++)
- {
- if ((byte & UTF8_SeqBits[i]) == UTF8_SeqBits[i-1])
- {
- ret = UTF8_SeqLens[i-1];
- break;
- }
- }
- return ret;
-}
-
-size_t utf8encode(char str[UTF_MAX], Rune rune)
-{
- size_t len = runelen(rune);
- str[0] = (len == 1 ? 0x00 : UTF8_SeqBits[len])
- | (UTF8_SeqMask[len] & (rune >> (6 * (len-1))));
- for (size_t i = 1; i < len; i++)
- str[i] = 0x80u | (0x3Fu & (rune >> (6 * (len-i-1))));
- return len;
-}
-
-bool utf8decode(Rune* rune, size_t* length, int byte)
-{
- /* Handle the start of a new rune */
- if (*length == 0) {
- /* If we were fed in an EOF as a start byte, handle it here */
- if (byte == EOF) {
- *rune = RUNE_EOF;
- } else {
- /* Otherwise, decode the first byte of the rune */
- *length = utfseq(byte);
- *rune = (*length == 0) ? RUNE_ERR : (byte & UTF8_SeqMask[*length]);
- (*length)--;
- }
- /* Handle continuation bytes */
- } else if ((byte & 0xC0) == 0x80) {
- /* add bits from continuation byte to rune value
- * cannot overflow: 6 byte sequences contain 31 bits */
- *rune = (*rune << 6) | (byte & 0x3F); /* 10xxxxxx */
- (*length)--;
- /* Sanity check the final rune value before finishing */
- if ((*length == 0) && !runevalid(*rune))
- *rune = RUNE_ERR;
- /* Didn't get the continuation byte we expected */
- } else {
- *rune = RUNE_ERR;
- }
- /* Tell the caller whether we finished or not */
- return ((*length == 0) || (*rune == RUNE_ERR));
-}
-
-int runewidth(unsigned col, Rune r)
-{
- int width;
- if (r == '\t')
- {
- width = (TabWidth - (col % TabWidth));
- }
- else
- {
- width = wcwidth(r);
- if (width < 0) width = 1;
- }
- return width;
-}
-
-bool risword(Rune r)
-{
- return (r < 127 && (isalnum(r) || r == '_' || r == '+' || r == '-'));
-}
-
-bool rissigil(Rune r)
-{
- return (r == ':' || r == '!' || r == '&' || r == '|' || r == '>' || r == '<');
-}
-
-bool risfile(Rune r)
-{
- return (risword(r) || r == '/' || r == '.' || r == ':' || r == '-' || r == '~');
-}
-
-bool riscmd(Rune r)
-{
- return (risword(r) || rissigil(r));
-}
-
-bool risblank(Rune r)
-{
- return (r == ' ' || r == '\t' || r == '\n' || r == '\r');
-}
-
-bool risbigword(Rune r)
-{
- return !risblank(r);
-}
-
+#include <liba.h>
#include <stdc.h>
#include "x11.h"
-#include "utf.h"
#include "io.h"
#include <locale.h>
#include <signal.h>
Int UTF8_Encode(Byte str[UTF_MAX], Rune rune);
Bool UTF8_Decode(Rune* rune, Int* length, Int byte);
+Int runewidth(unsigned col, Rune r);
+Bool risword(Rune r);
+Bool rissigil(Rune r);
+Bool risfile(Rune r);
+Bool riscmd(Rune r);
+Bool risblank(Rune r);
+Bool risbigword(Rune r);
+
/*
File I/O
*/
Int File_Read(File f, char* buf, Uint bufsz);
Int File_Write(File f, char* buf, Uint bufsz);
char* File_ReadAll(char* path);
+char* File_AbsolutePath(char* path);
+/*
+ Telemetry Output
+*/
+void Telemetry_Send(char* fmt, ...);
/*
Message Bus Interface
#include <fcntl.h>
#include <sys/stat.h>
#include <stdlib.h>
+#include <string.h>
File File_OpenForRead(char* path)
{
return data;
}
+char* File_AbsolutePath(char* path)
+{
+ char* ap = realpath(path, NULL);
+ if (!ap)
+ {
+ ap = strdup(path);
+ }
+ return ap;
+}
#include <liba.h>
-
#include <stdc.h>
#include <time.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <pwd.h>
-
static int TelemFd = -1;
static char TelemBuf[16384];
return path;
}
-void telem_send(char* fmt, ...)
+void Telemetry_Send(char* fmt, ...)
{
char* str = TelemBuf;
size_t nleft = sizeof(TelemBuf);
+#define _XOPEN_SOURCE 700
#include <liba.h>
+#include <ctype.h>
+#include <wchar.h>
+
+#define TabWidth 4
static const Byte UTF8_SeqBits[] = { 0x00u, 0x80u, 0xC0u, 0xE0u, 0xF0u, 0xF8u, 0xFCu, 0xFEu };
static const Byte UTF8_SeqMask[] = { 0x00u, 0xFFu, 0x1Fu, 0x0Fu, 0x07u, 0x03u, 0x01u, 0x00u };
/* Tell the caller whether we finished or not */
return ((*length == 0) || (*rune == RUNE_ERR));
}
+
+Int runewidth(unsigned col, Rune r)
+{
+ Int width;
+ if (r == '\t')
+ {
+ width = (TabWidth - (col % TabWidth));
+ }
+ else
+ {
+ width = wcwidth(r);
+ if (width < 0) width = 1;
+ }
+ return width;
+}
+
+Bool risword(Rune r)
+{
+ return (r < 127 && (isalnum(r) || r == '_' || r == '+' || r == '-'));
+}
+
+Bool rissigil(Rune r)
+{
+ return (r == ':' || r == '!' || r == '&' || r == '|' || r == '>' || r == '<');
+}
+
+Bool risfile(Rune r)
+{
+ return (risword(r) || r == '/' || r == '.' || r == ':' || r == '-' || r == '~');
+}
+
+Bool riscmd(Rune r)
+{
+ return (risword(r) || rissigil(r));
+}
+
+Bool risblank(Rune r)
+{
+ return (r == ' ' || r == '\t' || r == '\n' || r == '\r');
+}
+
+Bool risbigword(Rune r)
+{
+ return !risblank(r);
+}