⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 win_environ.c

📁 操作系统SunOS 4.1.3版本的源码
💻 C
字号:
#ifndef lint#ifdef sccsstatic	char sccsid[] = "@(#)win_environ.c 1.1 92/07/30 Copyr 1983 Sun Micro";#endif#endif/* * Copyright (c) 1983 by Sun Microsystems, Inc. *//* * Implement the win_environ.h & win_sig.h interfaces. * (see win_ttyenv.c for other functions) */#include <sunwindow/rect.h>#include <sunwindow/win_environ.h>#include <sunwindow/win_struct.h>extern char *sprintf();/* * Public routines */we_setparentwindow(windevname)	char	*windevname;{	(void)setenv(WE_PARENT, windevname);}intwe_getparentwindow(windevname)	char	*windevname;{	return(_we_setstrfromenvironment(WE_PARENT, windevname));}we_setinitdata(initialrect, initialsavedrect, iconic)	struct	rect *initialrect, *initialsavedrect;	int	iconic;{	char rectstr[60];	rectstr[0] = '\0';	(void)sprintf(rectstr, "%04d,%04d,%04d,%04d,%04d,%04d,%04d,%04d,%04ld",		initialrect->r_left, initialrect->r_top,		initialrect->r_width, initialrect->r_height,		initialsavedrect->r_left, initialsavedrect->r_top,		initialsavedrect->r_width, initialsavedrect->r_height,		iconic);	(void)setenv(WE_INITIALDATA, rectstr);}intwe_getinitdata(initialrect, initialsavedrect, iconic)	struct	rect *initialrect, *initialsavedrect;	int	*iconic;{	char rectstr[60];	if (_we_setstrfromenvironment(WE_INITIALDATA, rectstr))		return(-1);	else {		if (sscanf(rectstr, "%hd,%hd,%hd,%hd,%hd,%hd,%hd,%hd,%hd",		    &initialrect->r_left, &initialrect->r_top,		    &initialrect->r_width, &initialrect->r_height,		    &initialsavedrect->r_left, &initialsavedrect->r_top,		    &initialsavedrect->r_width, &initialsavedrect->r_height,		    iconic)!=9)			return(-1);		return(0);	}}we_clearinitdata(){	(void)unsetenv(WE_INITIALDATA);}we_setgfxwindow(windevname)	char	*windevname;{	(void)setenv(WE_GFX, windevname);}intwe_getgfxwindow(windevname)	char	*windevname;{	return(_we_setstrfromenvironment(WE_GFX, windevname));}we_setmywindow(windevname)	char	*windevname;{	(void)setenv(WE_ME, windevname);}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -