摘要:
在Gnome的文件管理器(nautilus)里,双击一个文件的时候,系统会自动调用相应的程序去打开这个文件。在Nautilus里通过右键菜单固然可以修改默认的打开方式,但是缺乏灵活性和可操作性,比如,不能删除一些候选的打开方式,不能批量增加一些打开方式等等。 GNMOE的打开方式的配...
阅读全文
posted @ 2011-03-03 12:43
潜龙9527
阅读(381)
推荐(0)
摘要:
一、准备编译安装包[root@oracleserver ~]# rpm -q gcc make binutils openmotif setarchcompat-db compat-gcc-c++ compat-libstdc++compat-libstdc++-develgcc-4.1.2-...
阅读全文
posted @ 2011-03-03 12:41
潜龙9527
阅读(149)
推荐(0)
摘要:
http://210.59.145.203/nanashi_07/enote/linux/d/diff.htmldiff功能用來比較檔案的相異同,如果是指定比較目錄,則diff只會比較目錄中相同檔名的檔案,而不會比較其中所含的子目錄。若是要連子目錄一起比較,就必須加入-r參數。當以-來代替檔名...
阅读全文
posted @ 2011-03-03 12:39
潜龙9527
阅读(388)
推荐(0)
摘要:
http://os.51cto.com 2010-03-29 10:16 佚名摘要:CentOS有很多常用的命令需要我们掌握,在这里向大家详细的介绍如何查看系统硬件信息,以及硬件的使用情况。下面所总结的十四个命令希望对大家的学习和工作有所帮助。标签...
阅读全文
posted @ 2011-03-03 12:36
潜龙9527
阅读(131)
推荐(0)
摘要:
使用C++标准程序库的输入输出流(I/O Stream)复制文件,存在许多的方法,方法一:逐个字符复制#include std::ifstream input("in",ios::binary);std::ofstream output("out",ios::binary);char ch;w...
阅读全文
posted @ 2011-03-03 12:33
潜龙9527
阅读(208)
推荐(0)
摘要:
在面向对象设计中,如何通过很小的设计改变就可以应对设计需求的变化,这是令设计者极为关注的问题。为此不少OO先驱提出了很多有关面向对象的设计原则用于指导OO的设计和开发。下面是几条与类设计相关的设计原则。 1. 开闭原则(the Open Closed Principle OCP) 一个...
阅读全文
posted @ 2011-03-03 12:32
潜龙9527
阅读(105)
推荐(0)
摘要:
在面向对象设计中,如何通过很小的设计改变就可以应对设计需求的变化,这是令设计者极为关注的问题。为此不少OO先驱提出了很多有关面向对象的设计原则用于指导OO的设计和开发。下面是几条与类设计相关的设计原则。 1. 开闭原则(the Open Closed Principle OCP) 一个...
阅读全文
posted @ 2011-03-03 12:32
潜龙9527
阅读(76)
推荐(0)
摘要:
发布者:chinaitlab 日期: 2010-12-06 00:00:00 随着Linux性能的不断提升和逐渐普及,会有越来越多的人在Linux下从事应用软件的开发。这里笔者根据从事Linux应用程序开发的经验,介绍Linux编程库使用的一些基础知识。 库的定义和种类 所谓...
阅读全文
posted @ 2011-03-03 12:30
潜龙9527
阅读(197)
推荐(0)
摘要:
功能 创建一个唯一的临时文件函数原型 char *tmpnam(char *sptr); sptr可以是NULL或者一个栈地址。当sptr为NULL时,返回一个内部静态内存地址(保存了临时文件名), 当下一次以NULL调用函数的时候,该内存会被修改。 栈地址必须至少有L_tmpn...
阅读全文
posted @ 2011-03-03 12:28
潜龙9527
阅读(208)
推荐(0)
摘要:
函数名: tell 功 能: 取文件指针的当前位置 用 法: long tell(int handle); 程序例: #include #include #include #include int main(void) { int handle; char msg[]...
阅读全文
posted @ 2011-03-03 12:27
潜龙9527
阅读(355)
推荐(0)
摘要:
函数名: swab 功 能: 交换字节 用 法: void swab (char *from, char *to, int nbytes); 程序例: #include #include #include char source[15] = "rFna koB...
阅读全文
posted @ 2011-03-03 12:15
潜龙9527
阅读(608)
推荐(0)
摘要:
MSDN 中文网站http://www.microsoft.com/china/msdn/ MSDN 开发中心http://www.microsoft.com/china/msdn/DeveloperCenter/default.mspx 名称:快速入门地址: http://chs.gotd...
阅读全文
posted @ 2011-01-07 17:53
潜龙9527
阅读(145)
推荐(0)
摘要:
语法: #include size_t strxfrm( char *str1, const char *str2,size_t num );功能:函数将字符串str2 的前num 个字符存储到字符串str1中。如果strcoll() 处理字符串str1和旧的字符串str2, 返回值...
阅读全文
posted @ 2011-01-04 14:07
潜龙9527
阅读(315)
推荐(0)
摘要:
概述实现 函数名: strstr 功 能: 在字符串中查找指定字符串的第一次出现 用 法: char *strstr(char *str1, char *str2); strstr原型:extern char *strstr(char *haystack, char *needle);...
阅读全文
posted @ 2011-01-04 14:06
潜龙9527
阅读(4048)
推荐(0)
摘要:
strspn(返回字符串中第一个在指定字符串中出现的字符下标) 表头文件 #include 定义函数 size_t strspn (const char *s,const char * accept); 函数说明 strspn()从参数s 字符串的开头计算连续的字符,而这些字符都完全...
阅读全文
posted @ 2011-01-04 14:04
潜龙9527
阅读(251)
推荐(0)
摘要:
原型:extern char *strdup(char *s); 用法:#include 功能:复制字符串s 说明:返回指向被复制的字符串的指针,所需空间由malloc()分配且可以由free()释放。 举例: // strdup.c #include #include ...
阅读全文
posted @ 2011-01-04 13:59
潜龙9527
阅读(307)
推荐(0)
摘要:
原型:extern char *strchr(const char *s,char c); 头文件:#include 功能:查找字符串s中首次出现字符c的位置 说明:返回首次出现c的位置的指针,如果s中不存在c则返回NULL。 举例1:(在Visual C++ 6.0中运行通过)...
阅读全文
posted @ 2011-01-04 13:57
潜龙9527
阅读(162)
推荐(0)
摘要:
函数名: peekb 功 能: 检查存储单元 用 法: char peekb (int segment, unsigned offset); segment为段基地址,offset偏移地址。 程序例: #include #include #include int ma...
阅读全文
posted @ 2011-01-04 13:56
潜龙9527
阅读(208)
推荐(0)
摘要:
函数名: movetext 功 能: 将屏幕文本从一个矩形区域拷贝到另一个矩形区域 用 法: int movetext(int left, int top, int right, int bottom, intnewleft, int newtop);程序例: #inclu...
阅读全文
posted @ 2010-12-28 12:58
潜龙9527
阅读(204)
推荐(0)
摘要:
函数名: modf 功 能: 把数分为整数和小数 (The modf function breaks down the floating-pointvalue x into fractional and integer parts, each of which has thesame si...
阅读全文
posted @ 2010-12-28 12:57
潜龙9527
阅读(201)
推荐(0)
摘要:
原型:extern void *memccpy(void *dest, void *src, unsigned charc, unsigned int count); 参数: dest Pointer to the destination. src Pointer to the so...
阅读全文
posted @ 2010-12-28 12:56
潜龙9527
阅读(459)
推荐(0)
摘要:
函数名: highvideo 功 能: 选择高亮度文本字符 用 法: void highvideo(void); 头文件: conio.h 程序例: #include #include int main(void) { clrscr(); low...
阅读全文
posted @ 2010-12-28 12:53
潜龙9527
阅读(256)
推荐(0)
摘要:
C函数名:fmod 功 能: 计算x对y的模, 即x/y的余数,若y是0,则返回NaN。 用 法: doublefmod(double x, double y); 需要头文件:math.h 程序例: #include #includ...
阅读全文
posted @ 2010-12-28 12:52
潜龙9527
阅读(1088)
推荐(0)
摘要:
函数名: delline 功 能: 在文本窗口中删去一行 用 法: void delline(void); 程序例: #include int main(void) { clrscr(); cprintf("The function DELLINE delet...
阅读全文
posted @ 2010-12-28 12:51
潜龙9527
阅读(308)
推荐(0)
摘要:
函数名: coreleft 功 能: 返回未使用内存的大小 用 法: unsigned coreleft(void); 程序例: #include #include int main(void) { printf("The difference betwee...
阅读全文
posted @ 2010-12-24 16:16
潜龙9527
阅读(211)
推荐(0)
摘要:
函数名: ceil 用 法: doubleceil(double x); 功 能: 返回大于或者等于指定表达式的最小整数 头文件:math.h 程序例 #include #include int main(void) { doublenumber...
阅读全文
posted @ 2010-12-24 16:15
潜龙9527
阅读(431)
推荐(0)
摘要:
函数简介 函数名: cabs(_cabs) 功 能:计算复数的绝对值 所属库:math.h 用 法: double _cabs(struct _complex z); 参数说明: struct _complex 定义在math.h下 st...
阅读全文
posted @ 2010-12-24 16:07
潜龙9527
阅读(450)
推荐(0)
摘要:
函数名: ldexp 功 能:计算value*2的幂 用 法: doubleldexp(double value, int exp); 返回值:re=value*2^exp 程序例: #include"stdio.h" #includ...
阅读全文
posted @ 2010-12-08 17:39
潜龙9527
阅读(147)
推荐(0)
摘要:
函数名: modf 功 能: 把数分为整数和小数 (The modf function breaks down the floating-pointvalue x into fractional and integer parts, each of which has thesame si...
阅读全文
posted @ 2010-12-08 17:23
潜龙9527
阅读(374)
推荐(0)
摘要:
函数名: frexp 功 能: 把一个浮点数分解为尾数和指数 原 型: double frexp( double x, int *expptr ); float frexp( float x, int * expptr); // C++ only long double f...
阅读全文
posted @ 2010-12-08 17:10
潜龙9527
阅读(377)
推荐(0)