X-Git-Url: http://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=form%2Ffld_def.c;h=32dc11ee275316e224c5c9b45338962488913c1c;hp=3b8ddbc6cab9c551d37dcb3aa35bc071a02218fc;hb=a8987e73ec254703634802b4f7ee30d3a485524d;hpb=661078ddbde3ce0f3b06e95642fbb9b5fef7dca1 diff --git a/form/fld_def.c b/form/fld_def.c index 3b8ddbc6..32dc11ee 100644 --- a/form/fld_def.c +++ b/form/fld_def.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 1998 Free Software Foundation, Inc. * + * Copyright (c) 1998-2002,2003 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -27,12 +27,12 @@ ****************************************************************************/ /**************************************************************************** - * Author: Juergen Pfeifer 1995,1997 * + * Author: Juergen Pfeifer, 1995,1997 * ****************************************************************************/ #include "form.priv.h" -MODULE_ID("$Id: fld_def.c,v 1.10 1998/02/11 12:13:43 tom Exp $") +MODULE_ID("$Id: fld_def.c,v 1.17 2003/11/08 21:15:02 Jonathon.Gray Exp $") /* this can't be readonly */ static FIELD default_field = { @@ -63,7 +63,7 @@ static FIELD default_field = { (char *)0 /* usrptr */ }; -FIELD *_nc_Default_Field = &default_field; +NCURSES_EXPORT_VAR(FIELD *) _nc_Default_Field = &default_field; /*--------------------------------------------------------------------------- | Facility : libnform @@ -73,14 +73,15 @@ FIELD *_nc_Default_Field = &default_field; | int *err ) | | Description : Create an argument structure for the specified type. -| Use the type-dependant argument list to construct +| Use the type-dependent argument list to construct | it. | | Return Values : Pointer to argument structure. Maybe NULL. -| In case of an error in *err an errorcounter is increased. +| In case of an error in *err an error counter is increased. +--------------------------------------------------------------------------*/ -TypeArgument* -_nc_Make_Argument(const FIELDTYPE *typ, va_list *ap, int *err) +NCURSES_EXPORT(TypeArgument*) +_nc_Make_Argument +(const FIELDTYPE *typ, va_list *ap, int *err) { TypeArgument *res = (TypeArgument *)0; TypeArgument *p; @@ -119,11 +120,12 @@ _nc_Make_Argument(const FIELDTYPE *typ, va_list *ap, int *err) | type. | | Return Values : Pointer to argument structure. Maybe NULL. -| In case of an error in *err an errorcounter is increased. +| In case of an error in *err an error counter is increased. +--------------------------------------------------------------------------*/ -TypeArgument* -_nc_Copy_Argument(const FIELDTYPE *typ, - const TypeArgument *argp, int *err) +NCURSES_EXPORT(TypeArgument*) +_nc_Copy_Argument + (const FIELDTYPE *typ, + const TypeArgument *argp, int *err) { TypeArgument *res = (TypeArgument *)0; TypeArgument *p; @@ -166,8 +168,9 @@ _nc_Copy_Argument(const FIELDTYPE *typ, | | Return Values : - +--------------------------------------------------------------------------*/ -void -_nc_Free_Argument(const FIELDTYPE * typ, TypeArgument * argp) +NCURSES_EXPORT(void) +_nc_Free_Argument +(const FIELDTYPE * typ, TypeArgument * argp) { if (!typ || !(typ->status & _HAS_ARGS)) return; @@ -193,10 +196,11 @@ _nc_Free_Argument(const FIELDTYPE * typ, TypeArgument * argp) | Description : Copy argument structure of field src to field dst | | Return Values : TRUE - copy worked -| FALSE - error occured +| FALSE - error occurred +--------------------------------------------------------------------------*/ -bool -_nc_Copy_Type(FIELD *dst, FIELD const *src) +NCURSES_EXPORT(bool) +_nc_Copy_Type +(FIELD *dst, FIELD const *src) { int err = 0; @@ -228,8 +232,8 @@ _nc_Copy_Type(FIELD *dst, FIELD const *src) | | Return Values : - +--------------------------------------------------------------------------*/ -void -_nc_Free_Type(FIELD *field) +NCURSES_EXPORT(void) +_nc_Free_Type (FIELD *field) { assert(field); if (field->type) @@ -253,7 +257,9 @@ _nc_Free_Type(FIELD *field) | | Return Values : Pointer to the new field or NULL if failure. +--------------------------------------------------------------------------*/ -FIELD *new_field(int rows, int cols, int frow, int fcol, int nrow, int nbuf) +NCURSES_EXPORT(FIELD *) +new_field +(int rows, int cols, int frow, int fcol, int nrow, int nbuf) { FIELD *New_Field = (FIELD *)0; int err = E_BAD_ARGUMENT; @@ -317,7 +323,8 @@ FIELD *new_field(int rows, int cols, int frow, int fcol, int nrow, int nbuf) | E_BAD_ARGUMENT - invalid field pointer | E_CONNECTED - field is connected +--------------------------------------------------------------------------*/ -int free_field(FIELD * field) +NCURSES_EXPORT(int) +free_field (FIELD * field) { if (!field) RETURN(E_BAD_ARGUMENT);