TODO: http://www120.pair.com/mccarthy/nextstep/intro.htmld/Workspace.html is the correct nextstep look.
WISH: OnTheSpot editing, or maybe switch to miiiiiiif
WISH: just for fun, do shade and tint with XRender.
-WISH: make builtin character glyphs optional
-SECURITY FIX: systems using openpty (most BSDs) had wrong permissions on
-the tty. Other systems (such as GNU/Linux) were not affected. Bug fixes:
-the meta8 option ("weird alt key behaviour") is no longer forcefully
-enabled. New features: urxvt now supports embedded perl, which can already
-do useful things and will certainly be extended in the future.
-
-6.3
+6.3 Wed Jan 4 22:37:10 CET 2006
- SECURITY FIX: on systems using openpty, permissions were
not correctly updated on the tty device and were left as
world-readable and world-writable (likely in original rxvt,
MWM-hints
EWMH-hints (pid, utf8 names) and protocols (ping)
- seperate underline colour
- settable border widths and borderless switch
- settable extra linespacing
+ seperate underline colour (-underlineColor)
+ settable border widths and borderless switch (-w, -b, -bl)
+ settable extra linespacing /-lsp)
iso-14755-2 and -3, and visual feedback
backindex and forwardindex escape sequence
window op and some xterm/OSC escape sequences
- tripleclickwords
- settable insecure mode
+ tripleclickwords (-tcw)
+ settable insecure mode (-insecure)
keysym remapping support
- cursor blinking and underline cursor
- -embed, -pty-fd and -hold options
+ cursor blinking and underline cursor (-cb, -uc)
+ XEmbed support (-embed)
+ user-pty (-pty-fd)
+ hold on exit (-hold)
+ skip builtin block graphics (-sbg)
+ sgr modes 90..97 and 100..107
--enable-iso14755 (default: on)
Enable extended ISO 14755 support (see rxvt(1), or doc/rxvt.1.txt).
<dt><strong><a name="item__2dfb_fontlist"><strong>-fb</strong> <em>fontlist</em></a></strong><br />
</dt>
<dd>
-Compile font-styles: The bold font list to use when <strong>bold</strong> characters are to
-be printed. See resource <strong>boldFont</strong> for details.
+Compile <em>font-styles</em>: The bold font list to use when <strong>bold</strong> characters
+are to be printed. See resource <strong>boldFont</strong> for details.
</dd>
<p></p>
<dt><strong><a name="item__2dfi_fontlist"><strong>-fi</strong> <em>fontlist</em></a></strong><br />
</dt>
<dd>
-Compile font-styles: The italic font list to use when <em>italic</em> characters are to
-be printed. See resource <strong>italicFont</strong> for details.
+Compile <em>font-styles</em>: The italic font list to use when <em>italic</em>
+characters are to be printed. See resource <strong>italicFont</strong> for details.
</dd>
<p></p>
<dt><strong><a name="item__2dfbi_fontlist"><strong>-fbi</strong> <em>fontlist</em></a></strong><br />
</dt>
<dd>
-Compile font-styles: The bold italic font list to use when <strong><em>bold
+Compile <em>font-styles</em>: The bold italic font list to use when <strong><em>bold
italic</em> </strong>> characters are to be printed. See resource <strong>boldItalicFont</strong>
for details.
</dd>
<dt><strong><a name="item__2dis_7c_2bis"><strong>-is</strong>|<strong>+is</strong></a></strong><br />
</dt>
<dd>
-Compile font-styles: Bold/Italic font styles imply high intensity
+Compile <em>font-styles</em>: Bold/Italic font styles imply high intensity
foreground/background (default). See resource <strong>intensityStyles</strong> for
details.
</dd>
decorations; resource <strong>borderLess</strong>.
</dd>
<p></p>
+<dt><strong><a name="item__2dsbg"><strong>-sbg</strong></a></strong><br />
+</dt>
+<dd>
+Compile <em>frills</em>: Disable the usage of the built-in block graphics/line
+drawing characters and just rely on what the specified fonts provide. Use
+this if you have a good font and want to use its block graphic glyphs;
+resource <strong>skipBuiltinGlyphs</strong>.
+</dd>
+<p></p>
<dt><strong><a name="item__2dlsp_number"><strong>-lsp</strong> <em>number</em></a></strong><br />
</dt>
<dd>
WM, the rxvt-unicode window will not have window decorations; option <strong>-bl</strong>.
</dd>
<p></p>
+<dt><strong><a name="item_skipbuiltinglyphs_3a_boolean"><strong>skipBuiltinGlyphs:</strong> <em>boolean</em></a></strong><br />
+</dt>
+<dd>
+Compile <em>frills</em>: Disable the usage of the built-in block graphics/line
+drawing characters and just rely on what the specified fonts provide. Use
+this if you have a good font and want to use its block graphic glyphs;
+option <strong>-sbg</strong>.
+</dd>
+<p></p>
<dt><strong><a name="item_termname_3a_termname"><strong>termName:</strong> <em>termname</em></a></strong><br />
</dt>
<dd>
section of @@RXVT_NAME@@(7).
.IP "\fB\-fb\fR \fIfontlist\fR" 4
.IX Item "-fb fontlist"
-Compile font\-styles: The bold font list to use when \fBbold\fR characters are to
-be printed. See resource \fBboldFont\fR for details.
+Compile \fIfont-styles\fR: The bold font list to use when \fBbold\fR characters
+are to be printed. See resource \fBboldFont\fR for details.
.IP "\fB\-fi\fR \fIfontlist\fR" 4
.IX Item "-fi fontlist"
-Compile font\-styles: The italic font list to use when \fIitalic\fR characters are to
-be printed. See resource \fBitalicFont\fR for details.
+Compile \fIfont-styles\fR: The italic font list to use when \fIitalic\fR
+characters are to be printed. See resource \fBitalicFont\fR for details.
.IP "\fB\-fbi\fR \fIfontlist\fR" 4
.IX Item "-fbi fontlist"
-Compile font\-styles: The bold italic font list to use when \fB\f(BIbold
+Compile \fIfont-styles\fR: The bold italic font list to use when \fB\f(BIbold
italic\fB\fR characters are to be printed. See resource \fBboldItalicFont\fR
for details.
.IP "\fB\-is\fR|\fB+is\fR" 4
.IX Item "-is|+is"
-Compile font\-styles: Bold/Italic font styles imply high intensity
+Compile \fIfont-styles\fR: Bold/Italic font styles imply high intensity
foreground/background (default). See resource \fBintensityStyles\fR for
details.
.IP "\fB\-name\fR \fIname\fR" 4
Compile \fIfrills\fR: Set \s-1MWM\s0 hints to request a borderless window, i.e.
if honoured by the \s-1WM\s0, the rxvt-unicode window will not have window
decorations; resource \fBborderLess\fR.
+.IP "\fB\-sbg\fR" 4
+.IX Item "-sbg"
+Compile \fIfrills\fR: Disable the usage of the built-in block graphics/line
+drawing characters and just rely on what the specified fonts provide. Use
+this if you have a good font and want to use its block graphic glyphs;
+resource \fBskipBuiltinGlyphs\fR.
.IP "\fB\-lsp\fR \fInumber\fR" 4
.IX Item "-lsp number"
Compile \fIfrills\fR: Lines (pixel height) to insert between each row of
.IX Item "borderLess: boolean"
Set \s-1MWM\s0 hints to request a borderless window, i.e. if honoured by the
\&\s-1WM\s0, the rxvt-unicode window will not have window decorations; option \fB\-bl\fR.
+.IP "\fBskipBuiltinGlyphs:\fR \fIboolean\fR" 4
+.IX Item "skipBuiltinGlyphs: boolean"
+Compile \fIfrills\fR: Disable the usage of the built-in block graphics/line
+drawing characters and just rely on what the specified fonts provide. Use
+this if you have a good font and want to use its block graphic glyphs;
+option \fB\-sbg\fR.
.IP "\fBtermName:\fR \fItermname\fR" 4
.IX Item "termName: termname"
Specifies the terminal type name to be set in the \fB\s-1TERM\s0\fR environment
FAQ section of rxvt(7).
-fb *fontlist*
- Compile font-styles: The bold font list to use when bold characters
- are to be printed. See resource boldFont for details.
+ Compile *font-styles*: The bold font list to use when bold
+ characters are to be printed. See resource boldFont for details.
-fi *fontlist*
- Compile font-styles: The italic font list to use when *italic*
+ Compile *font-styles*: The italic font list to use when *italic*
characters are to be printed. See resource italicFont for details.
-fbi *fontlist*
- Compile font-styles: The bold italic font list to use when *bold
+ Compile *font-styles*: The bold italic font list to use when *bold
italic* characters are to be printed. See resource boldItalicFont
for details.
-is|+is
- Compile font-styles: Bold/Italic font styles imply high intensity
+ Compile *font-styles*: Bold/Italic font styles imply high intensity
foreground/background (default). See resource intensityStyles for
details.
if honoured by the WM, the rxvt-unicode window will not have window
decorations; resource borderLess.
+ -sbg
+ Compile *frills*: Disable the usage of the built-in block
+ graphics/line drawing characters and just rely on what the specified
+ fonts provide. Use this if you have a good font and want to use its
+ block graphic glyphs; resource skipBuiltinGlyphs.
+
-lsp *number*
Compile *frills*: Lines (pixel height) to insert between each row of
the display. Useful to work around font rendering problems; resource
the WM, the rxvt-unicode window will not have window decorations;
option -bl.
+ skipBuiltinGlyphs: *boolean*
+ Compile *frills*: Disable the usage of the built-in block
+ graphics/line drawing characters and just rely on what the specified
+ fonts provide. Use this if you have a good font and want to use its
+ block graphic glyphs; option -sbg.
+
termName: *termname*
Specifies the terminal type name to be set in the TERM environment
variable; option -tn.
<pre>
MWM-hints
EWMH-hints (pid, utf8 names) and protocols (ping)
- seperate underline colour
- settable border widths and borderless switch
- settable extra linespacing
+ seperate underline colour (-underlineColor)
+ settable border widths and borderless switch (-w, -b, -bl)
+ settable extra linespacing /-lsp)
iso-14755-2 and -3, and visual feedback
backindex and forwardindex escape sequence
window op and some xterm/OSC escape sequences
- tripleclickwords
- settable insecure mode
+ tripleclickwords (-tcw)
+ settable insecure mode (-insecure)
keysym remapping support
- cursor blinking and underline cursor
- -embed, -pty-fd and -hold options</pre>
+ cursor blinking and underline cursor (-cb, -uc)
+ XEmbed support (-embed)
+ user-pty (-pty-fd)
+ hold on exit (-hold)
+ skip builtin block graphics (-sbg)
+ sgr modes 90..97 and 100..107</pre>
</dd>
<p></p>
<dt><strong><a name="item_iso14755">--enable-iso14755 (default: on)</a></strong><br />
.\" ========================================================================
.\"
.IX Title "rxvt 7"
-.TH rxvt 7 "2006-01-04" "6.2" "RXVT-UNICODE"
+.TH rxvt 7 "2006-01-04" "6.3" "RXVT-UNICODE"
.SH "NAME"
RXVT REFERENCE \- FAQ, command sequences and other background information
.SH "SYNOPSIS"
A non-exhaustive list of features enabled by \f(CW\*(C`\-\-enable\-frills\*(C'\fR (possibly
in combination with other switches) is:
.Sp
-.Vb 13
+.Vb 17
\& MWM-hints
\& EWMH-hints (pid, utf8 names) and protocols (ping)
-\& seperate underline colour
-\& settable border widths and borderless switch
-\& settable extra linespacing
+\& seperate underline colour (-underlineColor)
+\& settable border widths and borderless switch (-w, -b, -bl)
+\& settable extra linespacing /-lsp)
\& iso-14755-2 and -3, and visual feedback
\& backindex and forwardindex escape sequence
\& window op and some xterm/OSC escape sequences
-\& tripleclickwords
-\& settable insecure mode
+\& tripleclickwords (-tcw)
+\& settable insecure mode (-insecure)
\& keysym remapping support
-\& cursor blinking and underline cursor
-\& -embed, -pty-fd and -hold options
+\& cursor blinking and underline cursor (-cb, -uc)
+\& XEmbed support (-embed)
+\& user-pty (-pty-fd)
+\& hold on exit (-hold)
+\& skip builtin block graphics (-sbg)
+\& sgr modes 90..97 and 100..107
.Ve
.IP "\-\-enable\-iso14755 (default: on)" 4
.IX Item "--enable-iso14755 (default: on)"
MWM-hints
EWMH-hints (pid, utf8 names) and protocols (ping)
- seperate underline colour
- settable border widths and borderless switch
- settable extra linespacing
+ seperate underline colour (-underlineColor)
+ settable border widths and borderless switch (-w, -b, -bl)
+ settable extra linespacing /-lsp)
iso-14755-2 and -3, and visual feedback
backindex and forwardindex escape sequence
window op and some xterm/OSC escape sequences
- tripleclickwords
- settable insecure mode
+ tripleclickwords (-tcw)
+ settable insecure mode (-insecure)
keysym remapping support
- cursor blinking and underline cursor
- -embed, -pty-fd and -hold options
+ cursor blinking and underline cursor (-cb, -uc)
+ XEmbed support (-embed)
+ user-pty (-pty-fd)
+ hold on exit (-hold)
+ skip builtin block graphics (-sbg)
+ sgr modes 90..97 and 100..107
--enable-iso14755 (default: on)
Enable extended ISO 14755 support (see rxvt(1), or doc/rxvt.1.txt).
utmpInhibit visualBell</pre>
</dd>
<p></p>
+<dt><strong><a name="item_screen_rstyle">$rend = $term->screen_rstyle ([$new_rstyle])</a></strong><br />
+</dt>
+<dd>
+Return and optionally change the current rendition. Text thta is output by
+the temrianl application will use this style.
+</dd>
+<p></p>
+<dt><strong><a name="item_screen_cur">($row, $col) = $term->screen_cur ([$row, $col])</a></strong><br />
+</dt>
+<dd>
+Return the current coordinates of the text cursor position and optionally
+set it (which is usually bad as applications don't expect that).
+</dd>
+<p></p>
<dt><strong><a name="item_selection_mark">($row, $col) = $term->selection_mark ([$row, $col])</a></strong><br />
</dt>
<dt><strong><a name="item_selection_beg">($row, $col) = $term->selection_beg ([$row, $col])</a></strong><br />
to the locale-specific encoding using <a href="#item_locale_encode"><code>$term->locale_encode</code></a>.
</dd>
<p></p>
-<dt><strong><a name="item_nrow">$nrow = $term->nrow</a></strong><br />
+<dt><strong><a name="item_width">$window_width = $term->width</a></strong><br />
</dt>
-<dt><strong><a name="item_ncol">$ncol = $term->ncol</a></strong><br />
+<dt><strong><a name="item_height">$window_height = $term->height</a></strong><br />
</dt>
-<dd>
-Return the number of rows/columns of the terminal window (i.e. as
-specified by <code>-geometry</code>, excluding any scrollback).
-</dd>
-<p></p>
-<dt><strong><a name="item_nsaved">$nsaved = $term->nsaved</a></strong><br />
+<dt><strong><a name="item_fwidth">$font_width = $term->fwidth</a></strong><br />
+</dt>
+<dt><strong><a name="item_fheight">$font_height = $term->fheight</a></strong><br />
+</dt>
+<dt><strong><a name="item_fbase">$font_ascent = $term->fbase</a></strong><br />
+</dt>
+<dt><strong><a name="item_nrow">$terminal_rows = $term->nrow</a></strong><br />
+</dt>
+<dt><strong><a name="item_ncol">$terminal_columns = $term->ncol</a></strong><br />
+</dt>
+<dt><strong><a name="item_focus">$has_focus = $term->focus</a></strong><br />
+</dt>
+<dt><strong><a name="item_mapped">$is_mapped = $term->mapped</a></strong><br />
+</dt>
+<dt><strong><a name="item_savelines">$max_scrollback = $term->saveLines</a></strong><br />
+</dt>
+<dt><strong><a name="item_total_rows">$nrow_plus_saveLines = $term->total_rows</a></strong><br />
+</dt>
+<dt><strong><a name="item_nsaved">$lines_in_scrollback = $term->nsaved</a></strong><br />
</dt>
<dd>
-Returns the number of lines in the scrollback buffer.
+Return various integers describing terminal characteristics.
</dd>
<p></p>
<dt><strong><a name="item_view_start">$view_start = $term->view_start ([$newvalue])</a></strong><br />
\& shade term_name title transparent transparent_all tripleclickwords
\& utmpInhibit visualBell
.Ve
+.ie n .IP "$rend = $term\->screen_rstyle ([$new_rstyle])" 4
+.el .IP "$rend = \f(CW$term\fR\->screen_rstyle ([$new_rstyle])" 4
+.IX Item "$rend = $term->screen_rstyle ([$new_rstyle])"
+Return and optionally change the current rendition. Text thta is output by
+the temrianl application will use this style.
+.ie n .IP "($row, $col\fR) = \f(CW$term\fR\->screen_cur ([$row, \f(CW$col])" 4
+.el .IP "($row, \f(CW$col\fR) = \f(CW$term\fR\->screen_cur ([$row, \f(CW$col\fR])" 4
+.IX Item "($row, $col) = $term->screen_cur ([$row, $col])"
+Return the current coordinates of the text cursor position and optionally
+set it (which is usually bad as applications don't expect that).
.ie n .IP "($row, $col\fR) = \f(CW$term\fR\->selection_mark ([$row, \f(CW$col])" 4
.el .IP "($row, \f(CW$col\fR) = \f(CW$term\fR\->selection_mark ([$row, \f(CW$col\fR])" 4
.IX Item "($row, $col) = $term->selection_mark ([$row, $col])"
Write the octets given in \f(CW$data\fR to the tty (i.e. as program input). To
pass characters instead of octets, you should convert your strings first
to the locale-specific encoding using \f(CW\*(C`$term\->locale_encode\*(C'\fR.
-.ie n .IP "$nrow = $term\->nrow" 4
-.el .IP "$nrow = \f(CW$term\fR\->nrow" 4
-.IX Item "$nrow = $term->nrow"
+.ie n .IP "$window_width = $term\->width" 4
+.el .IP "$window_width = \f(CW$term\fR\->width" 4
+.IX Item "$window_width = $term->width"
.PD 0
-.ie n .IP "$ncol = $term\->ncol" 4
-.el .IP "$ncol = \f(CW$term\fR\->ncol" 4
-.IX Item "$ncol = $term->ncol"
+.ie n .IP "$window_height = $term\->height" 4
+.el .IP "$window_height = \f(CW$term\fR\->height" 4
+.IX Item "$window_height = $term->height"
+.ie n .IP "$font_width = $term\->fwidth" 4
+.el .IP "$font_width = \f(CW$term\fR\->fwidth" 4
+.IX Item "$font_width = $term->fwidth"
+.ie n .IP "$font_height = $term\->fheight" 4
+.el .IP "$font_height = \f(CW$term\fR\->fheight" 4
+.IX Item "$font_height = $term->fheight"
+.ie n .IP "$font_ascent = $term\->fbase" 4
+.el .IP "$font_ascent = \f(CW$term\fR\->fbase" 4
+.IX Item "$font_ascent = $term->fbase"
+.ie n .IP "$terminal_rows = $term\->nrow" 4
+.el .IP "$terminal_rows = \f(CW$term\fR\->nrow" 4
+.IX Item "$terminal_rows = $term->nrow"
+.ie n .IP "$terminal_columns = $term\->ncol" 4
+.el .IP "$terminal_columns = \f(CW$term\fR\->ncol" 4
+.IX Item "$terminal_columns = $term->ncol"
+.ie n .IP "$has_focus = $term\->focus" 4
+.el .IP "$has_focus = \f(CW$term\fR\->focus" 4
+.IX Item "$has_focus = $term->focus"
+.ie n .IP "$is_mapped = $term\->mapped" 4
+.el .IP "$is_mapped = \f(CW$term\fR\->mapped" 4
+.IX Item "$is_mapped = $term->mapped"
+.ie n .IP "$max_scrollback = $term\->saveLines" 4
+.el .IP "$max_scrollback = \f(CW$term\fR\->saveLines" 4
+.IX Item "$max_scrollback = $term->saveLines"
+.ie n .IP "$nrow_plus_saveLines = $term\->total_rows" 4
+.el .IP "$nrow_plus_saveLines = \f(CW$term\fR\->total_rows" 4
+.IX Item "$nrow_plus_saveLines = $term->total_rows"
+.ie n .IP "$lines_in_scrollback = $term\->nsaved" 4
+.el .IP "$lines_in_scrollback = \f(CW$term\fR\->nsaved" 4
+.IX Item "$lines_in_scrollback = $term->nsaved"
.PD
-Return the number of rows/columns of the terminal window (i.e. as
-specified by \f(CW\*(C`\-geometry\*(C'\fR, excluding any scrollback).
-.ie n .IP "$nsaved = $term\->nsaved" 4
-.el .IP "$nsaved = \f(CW$term\fR\->nsaved" 4
-.IX Item "$nsaved = $term->nsaved"
-Returns the number of lines in the scrollback buffer.
+Return various integers describing terminal characteristics.
.ie n .IP "$view_start = $term\->view_start ([$newvalue])" 4
.el .IP "$view_start = \f(CW$term\fR\->view_start ([$newvalue])" 4
.IX Item "$view_start = $term->view_start ([$newvalue])"
shade term_name title transparent transparent_all tripleclickwords
utmpInhibit visualBell
+ $rend = $term->screen_rstyle ([$new_rstyle])
+ Return and optionally change the current rendition. Text thta is
+ output by the temrianl application will use this style.
+
+ ($row, $col) = $term->screen_cur ([$row, $col])
+ Return the current coordinates of the text cursor position and
+ optionally set it (which is usually bad as applications don't expect
+ that).
+
($row, $col) = $term->selection_mark ([$row, $col])
($row, $col) = $term->selection_beg ([$row, $col])
($row, $col) = $term->selection_end ([$row, $col])
strings first to the locale-specific encoding using
"$term->locale_encode".
- $nrow = $term->nrow
- $ncol = $term->ncol
- Return the number of rows/columns of the terminal window (i.e. as
- specified by "-geometry", excluding any scrollback).
-
- $nsaved = $term->nsaved
- Returns the number of lines in the scrollback buffer.
+ $window_width = $term->width
+ $window_height = $term->height
+ $font_width = $term->fwidth
+ $font_height = $term->fheight
+ $font_ascent = $term->fbase
+ $terminal_rows = $term->nrow
+ $terminal_columns = $term->ncol
+ $has_focus = $term->focus
+ $is_mapped = $term->mapped
+ $max_scrollback = $term->saveLines
+ $nrow_plus_saveLines = $term->total_rows
+ $lines_in_scrollback = $term->nsaved
+ Return various integers describing terminal characteristics.
$view_start = $term->view_start ([$newvalue])
Returns the negative row number of the topmost line. Minimum value
text = new text_t *[h];
rend = new rend_t *[h];
-
+
for (int y = 0; y < h; y++)
- {
+ {
text_t *tp = text[y] = new text_t[w];
rend_t *rp = rend[y] = new rend_t[w];
-
+
text_t t0, t1, t2;
rend_t r = rstyle;
-
+
if (border == 2)
{
if (y == 0)
t0 = 0x2551, t1 = 0x0020, t2 = 0x2551;
else
t0 = 0x255a, t1 = 0x2550, t2 = 0x255d;
-
- *tp++ = t0;
+
+ *tp++ = t0;
*rp++ = r;
-
+
for (int x = w - 2; x-- > 0; )
{
*tp++ = t1;
*rp++ = r;
- }
+ }
*tp = t2;
- *rp = r;
+ *rp = r;
}
else
for (int x = w; x-- > 0; )
{
*tp++ = 0x0020;
*rp++ = r;
- }
- }
+ }
+ }
show ();
THIS->want_refresh = 1;
{
text_t *t1 = text [y];
rend_t *r1 = rend [y];
-
+
text_t *t2 = ROW(y + ov_y - THIS->view_start).t + ov_x;
rend_t *r2 = ROW(y + ov_y - THIS->view_start).r + ov_x;
for (int x = ov_w; x--; )
- {
+ {
text_t t = *t1; *t1++ = *t2; *t2++ = t;
rend_t r = *r1; *r1++ = *r2; *r2++ = SET_FONT (r, THIS->fontset [GET_STYLE (r)]->find_font (t));
}
for (int col = min (wcslen (wtext), w - x - border); col--; )
this->text [y][x + col] = wtext [col];
-
+
free (wtext);
if (rend)
{
if (!perl)
return false;
-
+
if (htype == HOOK_INIT) // first hook ever called
{
term->self = (void *)newSVptr ((void *)term, "urxvt::term");
OUTPUT:
RETVAL
+# very portable, especially on objects as opposed to pods
+#define TERM_OFFSET(sym) (((char *)&((TermWin_t *)0)->sym) - (char *)(TermWin_t *)0)
+
+#define TERM_OFFSET_width TERM_OFFSET(width)
+#define TERM_OFFSET_height TERM_OFFSET(height)
+#define TERM_OFFSET_fwidth TERM_OFFSET(fwidth)
+#define TERM_OFFSET_fheight TERM_OFFSET(fheight)
+#define TERM_OFFSET_fbase TERM_OFFSET(fbase)
+#define TERM_OFFSET_nrow TERM_OFFSET(nrow)
+#define TERM_OFFSET_ncol TERM_OFFSET(ncol)
+#define TERM_OFFSET_focus TERM_OFFSET(focus)
+#define TERM_OFFSET_mapped TERM_OFFSET(mapped)
+#define TERM_OFFSET_saveLines TERM_OFFSET(saveLines)
+#define TERM_OFFSET_total_rows TERM_OFFSET(total_rows)
+#define TERM_OFFSET_nsaved TERM_OFFSET(nsaved)
+
int
-rxvt_term::nsaved ()
+rxvt_term::width ()
+ ALIAS:
+ width = TERM_OFFSET_width
+ height = TERM_OFFSET_height
+ fwidth = TERM_OFFSET_fwidth
+ fheight = TERM_OFFSET_fheight
+ fbase = TERM_OFFSET_fbase
+ nrow = TERM_OFFSET_nrow
+ ncol = TERM_OFFSET_ncol
+ focus = TERM_OFFSET_focus
+ mapped = TERM_OFFSET_mapped
+ saveLines = TERM_OFFSET_saveLines
+ total_rows = TERM_OFFSET_total_rows
+ nsaved = TERM_OFFSET_nsaved
CODE:
- RETVAL = THIS->nsaved;
+ RETVAL = *(int *)((char *)THIS + ix);
OUTPUT:
RETVAL
+U32
+rxvt_term::screen_rstyle (U32 new_rstyle = THIS->screen.s_rstyle)
+ CODE:
+{
+ RETVAL = THIS->screen.s_rstyle;
+ THIS->screen.s_rstyle = new_rstyle;
+}
+ OUTPUT:
+ RETVAL
+
int
rxvt_term::view_start (int newval = -1)
CODE:
OUTPUT:
RETVAL
-int
-rxvt_term::nrow ()
- CODE:
- RETVAL = THIS->nrow;
- OUTPUT:
- RETVAL
-
-int
-rxvt_term::ncol ()
- CODE:
- RETVAL = THIS->ncol;
- OUTPUT:
- RETVAL
-
void
rxvt_term::want_refresh ()
CODE:
}
void
-rxvt_term::selection_mark (...)
+rxvt_term::cur (...)
PROTOTYPE: $;$$
ALIAS:
- selection_beg = 1
- selection_end = 2
+ screen_cur = 0
+ selection_beg = 1
+ selection_end = 2
+ selection_mark = 3
PPCODE:
{
- row_col_t &sel = ix == 1 ? THIS->selection.beg
- : ix == 2 ? THIS->selection.end
- : THIS->selection.mark;
+ row_col_t &rc = ix == 0 ? THIS->screen.cur
+ : ix == 1 ? THIS->selection.beg
+ : ix == 2 ? THIS->selection.end
+ : THIS->selection.mark;
if (GIMME_V != G_VOID)
{
EXTEND (SP, 2);
- PUSHs (sv_2mortal (newSViv (sel.row)));
- PUSHs (sv_2mortal (newSViv (sel.col)));
+ PUSHs (sv_2mortal (newSViv (rc.row)));
+ PUSHs (sv_2mortal (newSViv (rc.col)));
}
if (items == 3)
{
- sel.row = clamp (SvIV (ST (1)), -THIS->nsaved, THIS->nrow - 1);
- sel.col = clamp (SvIV (ST (2)), 0, THIS->ncol - 1);
+ rc.row = clamp (SvIV (ST (1)), -THIS->nsaved, THIS->nrow - 1);
+ rc.col = clamp (SvIV (ST (2)), 0, THIS->ncol - 1);
if (ix)
THIS->want_refresh = 1;
THIS->selection.len = wcslen (THIS->selection.text);
}
}
-
+
void
rxvt_term::tt_write (SV *octets)
INIT:
goto &urxvt::term::_resource;
}
+=item $rend = $term->screen_rstyle ([$new_rstyle])
+
+Return and optionally change the current rendition. Text thta is output by
+the temrianl application will use this style.
+
+=item ($row, $col) = $term->screen_cur ([$row, $col])
+
+Return the current coordinates of the text cursor position and optionally
+set it (which is usually bad as applications don't expect that).
+
=item ($row, $col) = $term->selection_mark ([$row, $col])
=item ($row, $col) = $term->selection_beg ([$row, $col])
pass characters instead of octets, you should convert your strings first
to the locale-specific encoding using C<< $term->locale_encode >>.
-=item $nrow = $term->nrow
+=item $window_width = $term->width
+
+=item $window_height = $term->height
+
+=item $font_width = $term->fwidth
+
+=item $font_height = $term->fheight
+
+=item $font_ascent = $term->fbase
+
+=item $terminal_rows = $term->nrow
+
+=item $terminal_columns = $term->ncol
+
+=item $has_focus = $term->focus
+
+=item $is_mapped = $term->mapped
-=item $ncol = $term->ncol
+=item $max_scrollback = $term->saveLines
-Return the number of rows/columns of the terminal window (i.e. as
-specified by C<-geometry>, excluding any scrollback).
+=item $nrow_plus_saveLines = $term->total_rows
-=item $nsaved = $term->nsaved
+=item $lines_in_scrollback = $term->nsaved
-Returns the number of lines in the scrollback buffer.
+Return various integers describing terminal characteristics.
=item $view_start = $term->view_start ([$newvalue])