Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

vor 3 Jahren
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
  2. <html>
  3. <!-- Created by GNU Texinfo 6.5, http://www.gnu.org/software/texinfo/ -->
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  6. <title>isprint (The Red Hat newlib C Library)</title>
  7. <meta name="description" content="isprint (The Red Hat newlib C Library)">
  8. <meta name="keywords" content="isprint (The Red Hat newlib C Library)">
  9. <meta name="resource-type" content="document">
  10. <meta name="distribution" content="global">
  11. <meta name="Generator" content="makeinfo">
  12. <link href="index.html#Top" rel="start" title="Top">
  13. <link href="Document-Index.html#Document-Index" rel="index" title="Document Index">
  14. <link href="Document-Index.html#SEC_Contents" rel="contents" title="Table of Contents">
  15. <link href="Ctype.html#Ctype" rel="up" title="Ctype">
  16. <link href="ispunct.html#ispunct" rel="next" title="ispunct">
  17. <link href="islower.html#islower" rel="prev" title="islower">
  18. <style type="text/css">
  19. <!--
  20. a.summary-letter {text-decoration: none}
  21. blockquote.indentedblock {margin-right: 0em}
  22. blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
  23. blockquote.smallquotation {font-size: smaller}
  24. div.display {margin-left: 3.2em}
  25. div.example {margin-left: 3.2em}
  26. div.lisp {margin-left: 3.2em}
  27. div.smalldisplay {margin-left: 3.2em}
  28. div.smallexample {margin-left: 3.2em}
  29. div.smalllisp {margin-left: 3.2em}
  30. kbd {font-style: oblique}
  31. pre.display {font-family: inherit}
  32. pre.format {font-family: inherit}
  33. pre.menu-comment {font-family: serif}
  34. pre.menu-preformatted {font-family: serif}
  35. pre.smalldisplay {font-family: inherit; font-size: smaller}
  36. pre.smallexample {font-size: smaller}
  37. pre.smallformat {font-family: inherit; font-size: smaller}
  38. pre.smalllisp {font-size: smaller}
  39. span.nolinebreak {white-space: nowrap}
  40. span.roman {font-family: initial; font-weight: normal}
  41. span.sansserif {font-family: sans-serif; font-weight: normal}
  42. ul.no-bullet {list-style: none}
  43. -->
  44. </style>
  45. </head>
  46. <body lang="en">
  47. <a name="isprint"></a>
  48. <div class="header">
  49. <p>
  50. Next: <a href="ispunct.html#ispunct" accesskey="n" rel="next">ispunct</a>, Previous: <a href="islower.html#islower" accesskey="p" rel="prev">islower</a>, Up: <a href="Ctype.html#Ctype" accesskey="u" rel="up">Ctype</a> &nbsp; [<a href="Document-Index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Document-Index.html#Document-Index" title="Index" rel="index">Index</a>]</p>
  51. </div>
  52. <hr>
  53. <a name="isprint_002c-isgraph_002c-isprint_005fl_002c-isgraph_005fl_002d_002d_002dprintable-character-predicates"></a>
  54. <h3 class="section">3.8 <code>isprint</code>, <code>isgraph</code>, <code>isprint_l</code>, <code>isgraph_l</code>&mdash;printable character predicates</h3>
  55. <a name="index-isprint"></a>
  56. <a name="index-isgraph"></a>
  57. <a name="index-isprint_005fl"></a>
  58. <a name="index-isgraph_005fl"></a>
  59. <p><strong>Synopsis</strong>
  60. </p><div class="example">
  61. <pre class="example">#include &lt;ctype.h&gt;
  62. int isprint(int <var>c</var>);
  63. int isgraph(int <var>c</var>);
  64. #include &lt;ctype.h&gt;
  65. int isprint_l(int <var>c</var>, locale_t <var>locale</var>);
  66. int isgraph_l(int <var>c</var>, locale_t <var>locale</var>);
  67. </pre></div>
  68. <p><strong>Description</strong><br>
  69. <code>isprint</code> is a macro which classifies singlebyte charset values by table
  70. lookup. It is a predicate returning non-zero for printable characters,
  71. and 0 for other character arguments. It is defined only if <var>c</var> is
  72. representable as an unsigned char or if <var>c</var> is EOF.
  73. </p>
  74. <p><code>isgraph</code> behaves identically to <code>isprint</code>, except that space characters
  75. are excluded.
  76. </p>
  77. <p><code>isprint_l</code>, <code>isgraph_l</code> are like <code>isprint</code>, <code>isgraph</code> but perform
  78. the check based on the locale specified by the locale object locale. If
  79. <var>locale</var> is LC_GLOBAL_LOCALE or not a valid locale object, the behaviour
  80. is undefined.
  81. </p>
  82. <p>You can use a compiled subroutine instead of the macro definition by
  83. undefining either macro using &lsquo;<code>#undef isprint</code>&rsquo; or &lsquo;<code>#undef isgraph</code>&rsquo;,
  84. or &lsquo;<code>#undef isprint_l</code>&rsquo; or &lsquo;<code>#undef isgraph_l</code>&rsquo;.
  85. </p>
  86. <br>
  87. <p><strong>Returns</strong><br>
  88. <code>isprint</code>, <code>isprint_l</code> return non-zero if <var>c</var> is a printing character.
  89. <code>isgraph</code>, <code>isgraph_l</code> return non-zero if <var>c</var> is a printing character
  90. except spaces.
  91. </p>
  92. <br>
  93. <p><strong>Portability</strong><br>
  94. <code>isprint</code> and <code>isgraph</code> are ANSI C.
  95. </p>
  96. <p>No supporting OS subroutines are required.
  97. </p>
  98. <br>
  99. </body>
  100. </html>