1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65
|
.\\" auto-generated by docbook2man-spec $Revision: 1.5 $
.TH "ggiOpen" "3ggi" "22 August 2001" "GGI" "LibGGI API"
.SH NAME
ggiOpen, ggiClose \- Open and close a visual
.SH SYNOPSIS
\fB#include <ggi/ggi.h>
.sp
ggi_visual_t ggiOpen(const char *\fIdisplay\fB,
\fI\&...\fB);
.sp
int ggiClose(ggi_visual_t \fIvis\fB);
\fR.SH "DESCRIPTION"
.PP
\fBggiOpen\fR opens a visual. The visual is specified as a display
string, followed by \fBNULL\fR. If only \fBNULL\fR is specified,
the default display target is opened. (This may be may be specified by
the user.)
.PP
The other arguments are for internal purposes only, such as
\fIargptr\fR, used to pass driver-specific, non-textual
information to the driver.
.PP
\fBggiClose\fR releases and destroys an open visual.
This will close X windows, return consoles to text-mode, etc.
.SH "RETURN VALUE"
.PP
\fBggiOpen\fR returns the opened visual (\fBggi_visual_t\fR), or
NULL for error.
.PP
\fBggiClose\fR returns 0 for OK, otherwise an error
code.
.SH "EXAMPLES"
.SS "OPEN AND CLOSING DEFAULT VISUAL"
.sp
.nf
ggi_visual_t vis = ggiOpen(NULL);
if(vis==NULL)
{
ggiPanic("Couldn't open default visual!\\n");
}
\fI/* do stuff */\fR
ggiClose(vis);
.sp
.fi
.SS "OPEN AND CLOSING A MEMORY VISUAL"
.sp
.nf
ggi_visual_t memvis = ggiOpen("display-memory", NULL);
if(memvis==NULL) {
return -1;
}
\fI/* do stuff */\fR
ggiClose(memvis);
.sp
.fi
.SH "SEE ALSO"
\fBggiInit\fR(3)
|