📄 tgoto.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"><html><head><!-- Copyright 1997 The Open Group, All Rights Reserved --><title>tgetent</title></head><body bgcolor=white><center><font size=2>The Single UNIX ® Specification, Version 2<br>Copyright © 1997 The Open Group</font></center><hr size=2 noshade><xref type="10" name="tgetent"></xref><h4><a name = "tag_002_001_040"> </a>NAME</h4><blockquote>tgetent, tgetflag, tgetnum, tgetstr, tgoto - <b>termcap</b> databaseemulation (<b>TO BE WITHDRAWN</b>)</blockquote><h4><a name = "tag_002_001_041"> </a>SYNOPSIS</h4><blockquote><pre><code>#include <<a href="term.h.html">term.h</a>>int tgetent(char *<i>bp</i>, const char *<i>name</i>);int tgetflag(char <i>id</i>[2]);int tgetnum(char <i>id</i>[2]);char *tgetstr(char <i>id</i>[2], char **<i>area</i>);char *tgoto(char *<i>cap</i>, int <i>col</i>, int <i>row</i>);</code></pre></blockquote><h4><a name = "tag_002_001_042"> </a>DESCRIPTION</h4><blockquote>The<i>tgetent()</i>function looks up the <b>termcap</b> entry for <i>name</i>. The emulationignores the buffer pointer <i>bp</i>.<p>The<i>tgetflag()</i>function gets the boolean entry for <i>id</i>.<p>The<i>tgetnum()</i>function gets the numeric entry for <i>id</i>.<p>The<i>tgetstr()</i>function gets the string entry for <i>id</i>. If<i>area</i>is not a null pointer and does not point to a null pointer,<i>tgetstr()</i>copies the string entry into the buffer pointed to by<i>*area</i>and advances the variable pointed to by<i>area</i>to the first byte after the copy of the string entry.<p>The<i>tgoto()</i>function instantiates the parameters<i>col</i>and<i>row</i>into the capability<i>cap</i>and returns a pointer to the resulting string.<p>All of the information availablein the <b>terminfo</b> database need not be available through these functions.</blockquote><h4><a name = "tag_002_001_043"> </a>RETURN VALUE</h4><blockquote>Upon successful completion, functions that return an integer return OK.Otherwise, they return ERR.<p>Functions that return pointers return a null pointer on error.</blockquote><h4><a name = "tag_002_001_044"> </a>ERRORS</h4><blockquote>No errors are defined.</blockquote><h4><a name = "tag_002_001_045"> </a>APPLICATION USAGE</h4><blockquote>These functions are included as a conversion aid for programs that use the<b>termcap</b> library. Their arguments are the same and the functions areemulated using the <b>terminfo</b> database.<p>These functions are only guaranteed to operate reliably on character sets inwhich each character fits into a single byte, whose attributes can beexpressed using only constants with the A_ prefix.<p>Any terminal capabilities from the <b>terminfo</b> database that cannot beretrieved using these interfaces can be retrieved using the interfacesdescribed on the<i><a href="tigetflag.html">tigetflag()</a></i>page.<p>Portable applications must use<i><a href="tputs.html">tputs()</a></i>to output the strings returned by<i>tgetstr()</i>and<i>tgoto()</i>.</blockquote><h4><a name = "tag_002_001_046"> </a>SEE ALSO</h4><blockquote><i><a href="../xsh/putc.html">putc()</a></i>,<i><a href="setupterm.html">setupterm()</a></i>,<i><a href="tigetflag.html">tigetflag()</a></i>,<i><a href="term.h.html"><term.h></a></i>.</blockquote><hr size=2 noshade><center><font size=2>UNIX ® is a registered Trademark of The Open Group.<br>Copyright © 1997 The Open Group<br> [ <a href="../index.html">Main Index</a> | <a href="../xshix.html">XSH</a> | <a href="../xcuix.html">XCU</a> | <a href="../xbdix.html">XBD</a> | <a href="../cursesix.html">XCURSES</a> | <a href="../xnsix.html">XNS</a> ]</font></center><hr size=2 noshade></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -