跳转到内容

isprint, isgraph : 可打印字符谓词

#include <ctype.h>
int isprint(int c);
int isgraph(int c);
```### 描述
isprint 是一个通过查表对 ASCII 整数值进行分类的宏。它是一个谓词,对于可打印字符返回非零值,对于其他字符参数返回 0。它仅在 isascii(c) 为真或 c 为 EOF 时有定义。
可以通过使用 `#undef isprint' 或 `#undef isgraph' 取消定义任一宏,来使用编译后的子程序代替宏定义。### 返回值
如果 c 是打印字符 (0x20--0x7E),isprint 返回非零值。isgraph 的行为与 isprint 相同,但排除了空格字符 (0x20)。
---
**权威来源**: BUSMASTER DITA help source `isprint.dita`, compiled into `BUSMASTER.CHM` with the application.