mirror of
git://git.code.sf.net/p/cdesktopenv/code
synced 2025-02-15 04:32:24 +00:00
Merge branch 'master' of ssh://git.code.sf.net/p/cdesktopenv/code
This commit is contained in:
commit
3a9bac86e3
14 changed files with 73 additions and 70 deletions
|
@ -1793,7 +1793,7 @@ RestoreSession(
|
||||||
|
|
||||||
xrm_name[0] = XrmStringToQuark ("dtterm");
|
xrm_name[0] = XrmStringToQuark ("dtterm");
|
||||||
xrm_name[1] = XrmStringToQuark ("numClonedTerms");
|
xrm_name[1] = XrmStringToQuark ("numClonedTerms");
|
||||||
xrm_name[2] = NULL;
|
xrm_name[2] = 0;
|
||||||
XrmQGetResource (db, xrm_name, xrm_name, &rep_type, &value);
|
XrmQGetResource (db, xrm_name, xrm_name, &rep_type, &value);
|
||||||
|
|
||||||
/* if we got nothing back, bail out... */
|
/* if we got nothing back, bail out... */
|
||||||
|
@ -1875,7 +1875,7 @@ RestoreTerm(
|
||||||
|
|
||||||
sprintf(buf, "dtterm_%d", termNum);
|
sprintf(buf, "dtterm_%d", termNum);
|
||||||
xrm_name[0] = XrmStringToQuark(buf);
|
xrm_name[0] = XrmStringToQuark(buf);
|
||||||
xrm_name[2] = NULL;
|
xrm_name[2] = 0;
|
||||||
|
|
||||||
/* Pass 1, before widget realization...
|
/* Pass 1, before widget realization...
|
||||||
*/
|
*/
|
||||||
|
@ -2088,7 +2088,7 @@ SetWorkSpaceHints
|
||||||
do {
|
do {
|
||||||
ptr = strchr (workspaces, ' ');
|
ptr = strchr (workspaces, ' ');
|
||||||
if (ptr != NULL)
|
if (ptr != NULL)
|
||||||
*ptr = NULL;
|
*ptr = 0;
|
||||||
thisWsAtom = None;
|
thisWsAtom = None;
|
||||||
|
|
||||||
/* if we haven't hit a match, try interning the atom... */
|
/* if we haven't hit a match, try interning the atom... */
|
||||||
|
|
|
@ -259,7 +259,7 @@ dttermNewHandler(
|
||||||
displayString = newDisplayString;
|
displayString = newDisplayString;
|
||||||
displayEnv = (char *)malloc(strlen("DISPLAY=") +
|
displayEnv = (char *)malloc(strlen("DISPLAY=") +
|
||||||
strlen(displayString) + 2);
|
strlen(displayString) + 2);
|
||||||
displayEnv[0]=NULL;
|
displayEnv[0]=0;
|
||||||
strcat(displayEnv, "DISPLAY=");
|
strcat(displayEnv, "DISPLAY=");
|
||||||
strcat(displayEnv, displayString);
|
strcat(displayEnv, displayString);
|
||||||
putenv(displayEnv);
|
putenv(displayEnv);
|
||||||
|
|
|
@ -33,6 +33,7 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
|
#include <stdlib.h>
|
||||||
#ifndef SVR4
|
#ifndef SVR4
|
||||||
#if !defined( SYSV )
|
#if !defined( SYSV )
|
||||||
#include <sys/resource.h>
|
#include <sys/resource.h>
|
||||||
|
|
|
@ -245,7 +245,7 @@ void makelist(ListData *ld)
|
||||||
existcode_num = 0;
|
existcode_num = 0;
|
||||||
for (i = 0; i < ld->allcode_num; i++) {
|
for (i = 0; i < ld->allcode_num; i++) {
|
||||||
code = *allcodep;
|
code = *allcodep;
|
||||||
pattern = FalReadFont(fid, code, NULL, NULL);
|
pattern = FalReadFont(fid, code, 0, 0);
|
||||||
if (fal_utyexists == 0) {
|
if (fal_utyexists == 0) {
|
||||||
*existcodep = *allcodep;
|
*existcodep = *allcodep;
|
||||||
existcodep++;
|
existcodep++;
|
||||||
|
@ -294,7 +294,7 @@ char *i2s(int code)
|
||||||
for (i = 0; ; i++) {
|
for (i = 0; ; i++) {
|
||||||
if (tmp < 16) {
|
if (tmp < 16) {
|
||||||
buf[i] = i2c(tmp);
|
buf[i] = i2c(tmp);
|
||||||
buf[i+1] = NULL;
|
buf[i+1] = 0;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
buf[i] = i2c(tmp % 16);
|
buf[i] = i2c(tmp % 16);
|
||||||
|
@ -309,7 +309,7 @@ char *i2s(int code)
|
||||||
*cp = buf[i];
|
*cp = buf[i];
|
||||||
cp++;
|
cp++;
|
||||||
}
|
}
|
||||||
*cp = NULL;
|
*cp = 0;
|
||||||
return (number);
|
return (number);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -181,7 +181,7 @@ extern char *bdftopcf;
|
||||||
#define SNFFONTC_ERROR -26
|
#define SNFFONTC_ERROR -26
|
||||||
|
|
||||||
#define SCAN_TO_NONSP(p) {\
|
#define SCAN_TO_NONSP(p) {\
|
||||||
while (*(p) != NULL) {\
|
while (*(p) != 0) {\
|
||||||
if ((*(p) == ' ') || (*(p) == TAB_CD) || (*(p) == 0xa1)) {\
|
if ((*(p) == ' ') || (*(p) == TAB_CD) || (*(p) == 0xa1)) {\
|
||||||
(p)++;\
|
(p)++;\
|
||||||
} else {\
|
} else {\
|
||||||
|
@ -191,7 +191,7 @@ extern char *bdftopcf;
|
||||||
}
|
}
|
||||||
|
|
||||||
#define SCAN_TO_SP(p) {\
|
#define SCAN_TO_SP(p) {\
|
||||||
while (*(p) != NULL) {\
|
while (*(p) != 0) {\
|
||||||
if ((*(p) == ' ') || (*(p) == TAB_CD) || (*(p) == 0xa1)) {\
|
if ((*(p) == ' ') || (*(p) == TAB_CD) || (*(p) == 0xa1)) {\
|
||||||
break;\
|
break;\
|
||||||
} else {\
|
} else {\
|
||||||
|
|
|
@ -188,7 +188,7 @@
|
||||||
/*
|
/*
|
||||||
* help message
|
* help message
|
||||||
*/
|
*/
|
||||||
#define COMM_HELP_MSG{ \
|
#define COMM_HELP_MSG { \
|
||||||
USAGE(" [-codeset number] [-help]\n"); \
|
USAGE(" [-codeset number] [-help]\n"); \
|
||||||
USAGE("\n"); \
|
USAGE("\n"); \
|
||||||
}
|
}
|
||||||
|
|
|
@ -687,7 +687,7 @@ int num;
|
||||||
FontScope scope;
|
FontScope scope;
|
||||||
ret = (ExtdSegment)Xmalloc(sizeof(ExtdSegmentRec));
|
ret = (ExtdSegment)Xmalloc(sizeof(ExtdSegmentRec));
|
||||||
if(ret == NULL){
|
if(ret == NULL){
|
||||||
return (NULL);
|
return (0);
|
||||||
}
|
}
|
||||||
if(strchr(value[0],':')){
|
if(strchr(value[0],':')){
|
||||||
ret->name = (char *)Xmalloc(strlen(value[0])+1);
|
ret->name = (char *)Xmalloc(strlen(value[0])+1);
|
||||||
|
@ -696,7 +696,7 @@ int num;
|
||||||
}
|
}
|
||||||
strcpy(ret->name,value[0]);
|
strcpy(ret->name,value[0]);
|
||||||
ptr = strchr(ret->name,':');
|
ptr = strchr(ret->name,':');
|
||||||
*ptr = NULL;
|
*ptr = 0;
|
||||||
ptr++;
|
ptr++;
|
||||||
if( !_fallcNCompareISOLatin1(ptr, "none", 4) ){
|
if( !_fallcNCompareISOLatin1(ptr, "none", 4) ){
|
||||||
ret->side = XlcNONE ;
|
ret->side = XlcNONE ;
|
||||||
|
@ -939,7 +939,7 @@ load_generic(lcd)
|
||||||
char tmp[128];
|
char tmp[128];
|
||||||
tmpb = (codeset->byteM)[M-1].byteinfo ;
|
tmpb = (codeset->byteM)[M-1].byteinfo ;
|
||||||
/* default 0x00 - 0xff */
|
/* default 0x00 - 0xff */
|
||||||
sscanf(value[ii],"\\x%lx,\\x%lx",&start,&end);
|
sscanf(value[ii], "\\x%lx,\\x%lx", (long unsigned *) &start, (long unsigned *) &end);
|
||||||
tmpb[ii].start = (unsigned char)start;
|
tmpb[ii].start = (unsigned char)start;
|
||||||
tmpb[ii].end = (unsigned char)end;
|
tmpb[ii].end = (unsigned char)end;
|
||||||
}
|
}
|
||||||
|
|
|
@ -172,7 +172,7 @@ long fb_default;
|
||||||
|
|
||||||
for(i = 0; i < NRUNE; i++)
|
for(i = 0; i < NRUNE; i++)
|
||||||
table[i] = -1;
|
table[i] = -1;
|
||||||
while((rv = fscanf(fptr, "%lx", &value)) != EOF) {
|
while((rv = fscanf(fptr, "%lx", (long unsigned *) &value)) != EOF) {
|
||||||
if(rv != 0 && value >= 0) {
|
if(rv != 0 && value >= 0) {
|
||||||
table[value] = j++;
|
table[value] = j++;
|
||||||
} else {
|
} else {
|
||||||
|
@ -532,11 +532,11 @@ long fb_default;
|
||||||
register int i = 0;
|
register int i = 0;
|
||||||
int j = 0;
|
int j = 0;
|
||||||
int rv = 0;
|
int rv = 0;
|
||||||
long value;
|
long value;
|
||||||
|
|
||||||
for(i = 0; i < NRUNE; i++)
|
for(i = 0; i < NRUNE; i++)
|
||||||
from_tbl[i] = -1;
|
from_tbl[i] = -1;
|
||||||
while((rv = fscanf(fptr, "%lx", &value)) != EOF) {
|
while((rv = fscanf(fptr, "%lx", (long unsigned *) &value)) != EOF) {
|
||||||
if(rv != 0) {
|
if(rv != 0) {
|
||||||
(*to_tbl)[j++] = value;
|
(*to_tbl)[j++] = value;
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -608,7 +608,7 @@ static char
|
||||||
return NULL;
|
return NULL;
|
||||||
strcpy(pattern, font_name);
|
strcpy(pattern, font_name);
|
||||||
|
|
||||||
memset(fields, NULL, sizeof(char *) * 14);
|
memset(fields, 0, sizeof(char *) * 14);
|
||||||
ptr = pattern;
|
ptr = pattern;
|
||||||
while(isspace(*ptr)) {
|
while(isspace(*ptr)) {
|
||||||
ptr++;
|
ptr++;
|
||||||
|
@ -644,7 +644,7 @@ static char
|
||||||
strcpy(str_point, "*");
|
strcpy(str_point, "*");
|
||||||
fields[POINT_SIZE_FIELD - 1] = str_point;
|
fields[POINT_SIZE_FIELD - 1] = str_point;
|
||||||
|
|
||||||
rotate_font[0] = NULL;
|
rotate_font[0] = '\0';
|
||||||
for(field_num = 0 ; field_num < CHARSET_ENCODING_FIELD &&
|
for(field_num = 0 ; field_num < CHARSET_ENCODING_FIELD &&
|
||||||
fields[field_num] ; field_num++) {
|
fields[field_num] ; field_num++) {
|
||||||
sprintf(rotate_font, "%s-%s", rotate_font, fields[field_num]);
|
sprintf(rotate_font, "%s-%s", rotate_font, fields[field_num]);
|
||||||
|
|
|
@ -2369,7 +2369,7 @@ FalFontData *fdata;
|
||||||
if ((fp = open_fonts_list()) == NULL) {
|
if ((fp = open_fonts_list()) == NULL) {
|
||||||
return FAL_ERROR ;
|
return FAL_ERROR ;
|
||||||
}
|
}
|
||||||
memset( pname, NULL, sizeof( pname ) );
|
memset( pname, 0, sizeof( pname ) );
|
||||||
|
|
||||||
while ( fgets( buf, FAL_LINE_MAX, fp ) != ( char * ) NULL ) {
|
while ( fgets( buf, FAL_LINE_MAX, fp ) != ( char * ) NULL ) {
|
||||||
int eq;
|
int eq;
|
||||||
|
@ -2523,7 +2523,7 @@ FalFontData *fdata;
|
||||||
fls->list = p_bak ;
|
fls->list = p_bak ;
|
||||||
}
|
}
|
||||||
|
|
||||||
memset( buf, NULL, sizeof(buf));
|
memset( buf, 0, sizeof(buf));
|
||||||
|
|
||||||
while( fgets( buf, FAL_LINE_MAX, fp ) != (char *)NULL ) {
|
while( fgets( buf, FAL_LINE_MAX, fp ) != (char *)NULL ) {
|
||||||
int tmp_num, eq ;
|
int tmp_num, eq ;
|
||||||
|
@ -2535,7 +2535,7 @@ FalFontData *fdata;
|
||||||
|
|
||||||
/* parse string of font file */
|
/* parse string of font file */
|
||||||
if( (ep = strchr( buf, ' ' )) == (char *)NULL ) continue ;
|
if( (ep = strchr( buf, ' ' )) == (char *)NULL ) continue ;
|
||||||
else *ep = NULL ;
|
else *ep = 0 ;
|
||||||
/* refuse font file (not gpf) */
|
/* refuse font file (not gpf) */
|
||||||
if(
|
if(
|
||||||
( strcmp( FILE_SUFFIX(buf), PCFSUFFIX ) != 0 ) &&
|
( strcmp( FILE_SUFFIX(buf), PCFSUFFIX ) != 0 ) &&
|
||||||
|
@ -2563,7 +2563,7 @@ FalFontData *fdata;
|
||||||
case _FAL_TRY_NEXT :
|
case _FAL_TRY_NEXT :
|
||||||
if( (func & SRCHFNAME) || (func & FONTOFID) ) FreeString( fontFileName ) ;
|
if( (func & SRCHFNAME) || (func & FONTOFID) ) FreeString( fontFileName ) ;
|
||||||
fal_clear_data( &tmp_data );
|
fal_clear_data( &tmp_data );
|
||||||
memset( buf, NULL, sizeof(buf));
|
memset( buf, 0, sizeof(buf));
|
||||||
continue ;
|
continue ;
|
||||||
case 0:
|
case 0:
|
||||||
if( (func & FONTOFID) ) FreeString( fontFileName ) ;
|
if( (func & FONTOFID) ) FreeString( fontFileName ) ;
|
||||||
|
@ -2577,7 +2577,7 @@ FalFontData *fdata;
|
||||||
if( !(func & FONTOFID) && (codeset_num == 0) ){
|
if( !(func & FONTOFID) && (codeset_num == 0) ){
|
||||||
if( (func & SRCHFNAME) ) FreeString( fontFileName ) ;
|
if( (func & SRCHFNAME) ) FreeString( fontFileName ) ;
|
||||||
fal_clear_data( &tmp_data );
|
fal_clear_data( &tmp_data );
|
||||||
memset( buf, NULL, sizeof(buf));
|
memset( buf, 0, sizeof(buf));
|
||||||
continue ;
|
continue ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2639,7 +2639,7 @@ FalFontData *fdata;
|
||||||
if( fal_read_fidinf( fid, &fontid_inf ) != FAL_ERROR )
|
if( fal_read_fidinf( fid, &fontid_inf ) != FAL_ERROR )
|
||||||
fdata->cd_set = fontid_inf.cd_set ;
|
fdata->cd_set = fontid_inf.cd_set ;
|
||||||
else {
|
else {
|
||||||
fdata->cd_set = NULL ;
|
fdata->cd_set = 0 ;
|
||||||
goto FalError ;
|
goto FalError ;
|
||||||
}
|
}
|
||||||
fclose(fp) ;
|
fclose(fp) ;
|
||||||
|
@ -3091,7 +3091,7 @@ unsigned int *glidx ;
|
||||||
/*
|
/*
|
||||||
* get string of "CHARSET_REGISTRY"
|
* get string of "CHARSET_REGISTRY"
|
||||||
*/
|
*/
|
||||||
memset( &tmp_data, NULL, sizeof(FalFontData) ) ;
|
memset( &tmp_data, 0, sizeof(FalFontData) ) ;
|
||||||
|
|
||||||
if( cmpfid != fid ){
|
if( cmpfid != fid ){
|
||||||
if( falReadGpfProp( FAL_READ_FONTINFO, finf, FAL_FONT_PRM, &tmp_data ) ) {
|
if( falReadGpfProp( FAL_READ_FONTINFO, finf, FAL_FONT_PRM, &tmp_data ) ) {
|
||||||
|
@ -3158,7 +3158,7 @@ unsigned int *code ;
|
||||||
/*
|
/*
|
||||||
* get string of "CHARSET_REGISTRY"
|
* get string of "CHARSET_REGISTRY"
|
||||||
*/
|
*/
|
||||||
memset( &tmp_data, NULL, sizeof(tmp_data) ) ;
|
memset( &tmp_data, 0, sizeof(tmp_data) ) ;
|
||||||
if( falReadGpfProp( FAL_READ_FONTINFO, finf, FAL_FONT_PRM, &tmp_data ) ) {
|
if( falReadGpfProp( FAL_READ_FONTINFO, finf, FAL_FONT_PRM, &tmp_data ) ) {
|
||||||
fal_clear_data( &tmp_data ) ;
|
fal_clear_data( &tmp_data ) ;
|
||||||
return FAL_ERROR;
|
return FAL_ERROR;
|
||||||
|
|
|
@ -98,7 +98,9 @@ pragma on(alloca);
|
||||||
|
|
||||||
|
|
||||||
#if defined(__GNUC__) || defined(__uxp__)
|
#if defined(__GNUC__) || defined(__uxp__)
|
||||||
|
#if !defined(linux)
|
||||||
#define alloca ___builtin_alloca
|
#define alloca ___builtin_alloca
|
||||||
|
#endif
|
||||||
#define ALLOCATE_LOCAL(size) alloca((int)(size))
|
#define ALLOCATE_LOCAL(size) alloca((int)(size))
|
||||||
#define DEALLOCATE_LOCAL(ptr) /* as nothing */
|
#define DEALLOCATE_LOCAL(ptr) /* as nothing */
|
||||||
#else /* ! __GNUC__ ! __uxp__ */
|
#else /* ! __GNUC__ ! __uxp__ */
|
||||||
|
|
|
@ -44,10 +44,10 @@ void _falmbDefaultDrawImageString() { return ; }
|
||||||
/* Atom */ falInternAtom() { return 0 ; }
|
/* Atom */ falInternAtom() { return 0 ; }
|
||||||
int _falwcGenericDrawString() { return 0 ; }
|
int _falwcGenericDrawString() { return 0 ; }
|
||||||
char **_falParseBaseFontNameList() { return NULL ; }
|
char **_falParseBaseFontNameList() { return NULL ; }
|
||||||
/* XFontStruct * */ falLoadQueryFont() { return NULL ; }
|
/* XFontStruct * */ falLoadQueryFont() { return 0 ; }
|
||||||
falFreeFont() { return 0 ; }
|
falFreeFont() { return 0 ; }
|
||||||
falFreeFontInfo() { return 0 ; }
|
falFreeFontInfo() { return 0 ; }
|
||||||
/* char ** */ falListFonts() { return NULL ; }
|
/* char ** */ falListFonts() { return 0 ; }
|
||||||
void _falmbGenericDrawImageString() { return ; }
|
void _falmbGenericDrawImageString() { return ; }
|
||||||
void _falwcDefaultDrawImageString() { return ; }
|
void _falwcDefaultDrawImageString() { return ; }
|
||||||
int _falmbDefaultDrawString() { return 0 ; }
|
int _falmbDefaultDrawString() { return 0 ; }
|
||||||
|
@ -56,7 +56,7 @@ void falFreeStringList() { return ; }
|
||||||
/* falrmStringToQuark() { return 0 ; } */
|
/* falrmStringToQuark() { return 0 ; } */
|
||||||
/* falrmPermStringToQuark() { return 0 ; } */
|
/* falrmPermStringToQuark() { return 0 ; } */
|
||||||
int _falwcDefaultDrawString() { return 0 ; }
|
int _falwcDefaultDrawString() { return 0 ; }
|
||||||
/* char * */ falGetAtomName() { return NULL ; }
|
/* char * */ falGetAtomName() { return 0 ; }
|
||||||
int _falwcGenericTextExtents() { return 0 ; }
|
int _falwcGenericTextExtents() { return 0 ; }
|
||||||
int _falmbGenericTextExtents() { return 0 ; }
|
int _falmbGenericTextExtents() { return 0 ; }
|
||||||
void _falwcGenericDrawImageString() { return ; }
|
void _falwcGenericDrawImageString() { return ; }
|
||||||
|
@ -67,7 +67,7 @@ int _falwcDefaultTextExtents() { return 0 ; }
|
||||||
int _falmbDefaultTextEscapement() { return 0 ; }
|
int _falmbDefaultTextEscapement() { return 0 ; }
|
||||||
int _falwcGenericTextEscapement() { return 0 ; }
|
int _falwcGenericTextEscapement() { return 0 ; }
|
||||||
int _falmbDefaultTextExtents() { return 0 ; }
|
int _falmbDefaultTextExtents() { return 0 ; }
|
||||||
/* char ** */ falListFontsWithInfo() { return NULL ; }
|
/* char ** */ falListFontsWithInfo() { return 0 ; }
|
||||||
int _falwcDefaultTextEscapement() { return 0 ; }
|
int _falwcDefaultTextEscapement() { return 0 ; }
|
||||||
/* Status */ _falwcGenericTextPerCharExtents(){ return 0 ; }
|
/* Status */ _falwcGenericTextPerCharExtents(){ return 0 ; }
|
||||||
/* _fallcMapOSLocaleName() { return 0 ; } */
|
/* _fallcMapOSLocaleName() { return 0 ; } */
|
||||||
|
|
|
@ -627,12 +627,12 @@ int bsize;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ptn[bsize - 1] = NULL;
|
ptn[bsize - 1] = 0;
|
||||||
|
|
||||||
for (i=0, skip=0; i<head->bdf_height; i++) {
|
for (i=0, skip=0; i<head->bdf_height; i++) {
|
||||||
if (skip) {
|
if (skip) {
|
||||||
for(j=0; j<mwidth; j++) {
|
for(j=0; j<mwidth; j++) {
|
||||||
ptn[j] = NULL;
|
ptn[j] = 0;
|
||||||
}
|
}
|
||||||
ptn += mwidth;
|
ptn += mwidth;
|
||||||
continue;
|
continue;
|
||||||
|
@ -645,7 +645,7 @@ int bsize;
|
||||||
if (!strncmp(p, ENDCHAR, ENDCHARsz)) {
|
if (!strncmp(p, ENDCHAR, ENDCHARsz)) {
|
||||||
skip = 1;
|
skip = 1;
|
||||||
for(j=0; j<mwidth; j++) {
|
for(j=0; j<mwidth; j++) {
|
||||||
ptn[j] = NULL;
|
ptn[j] = 0;
|
||||||
}
|
}
|
||||||
ptn += mwidth;
|
ptn += mwidth;
|
||||||
continue;
|
continue;
|
||||||
|
@ -764,7 +764,7 @@ int bsize;
|
||||||
for (i=0, skip=0; i<head->p_height; i++) {
|
for (i=0, skip=0; i<head->p_height; i++) {
|
||||||
if (skip) {
|
if (skip) {
|
||||||
for (j=0; j<mwidth; j++) {
|
for (j=0; j<mwidth; j++) {
|
||||||
ptn[j] = NULL;
|
ptn[j] = 0;
|
||||||
}
|
}
|
||||||
ptn += mwidth;
|
ptn += mwidth;
|
||||||
continue;
|
continue;
|
||||||
|
@ -778,7 +778,7 @@ int bsize;
|
||||||
(!strncmp(p, ENDDATA, ENDDATAsz))) {
|
(!strncmp(p, ENDDATA, ENDDATAsz))) {
|
||||||
skip = 1;
|
skip = 1;
|
||||||
for (j=0; j<mwidth; j++) {
|
for (j=0; j<mwidth; j++) {
|
||||||
ptn[j] = NULL;
|
ptn[j] = 0;
|
||||||
}
|
}
|
||||||
ptn += mwidth;
|
ptn += mwidth;
|
||||||
continue;
|
continue;
|
||||||
|
@ -808,7 +808,7 @@ int width;
|
||||||
int i, iend, len;
|
int i, iend, len;
|
||||||
char *p, str[3];
|
char *p, str[3];
|
||||||
|
|
||||||
str[2] = NULL;
|
str[2] = 0;
|
||||||
|
|
||||||
SCAN_TO_NONSP(buf);
|
SCAN_TO_NONSP(buf);
|
||||||
|
|
||||||
|
@ -829,7 +829,7 @@ int width;
|
||||||
}
|
}
|
||||||
if (iend%2) {
|
if (iend%2) {
|
||||||
str[0] = *buf;
|
str[0] = *buf;
|
||||||
str[1] = NULL;
|
str[1] = 0;
|
||||||
*mem = (char)strtol(str, NULL, 16) << 4;
|
*mem = (char)strtol(str, NULL, 16) << 4;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -857,11 +857,11 @@ int width;
|
||||||
|
|
||||||
for (i=0, skip=0; i<iend; i++) {
|
for (i=0, skip=0; i<iend; i++) {
|
||||||
if (skip) {
|
if (skip) {
|
||||||
*mem++ = NULL;
|
*mem++ = 0;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
for (j=0, ptn = NULL; j<8; j++) {
|
for (j=0, ptn = 0; j<8; j++) {
|
||||||
if ((*buf == '\n') || (*buf == NULL)) {
|
if ((*buf == '\n') || (*buf == 0)) {
|
||||||
skip = 1;
|
skip = 1;
|
||||||
ptn <<= (8-j);
|
ptn <<= (8-j);
|
||||||
break;
|
break;
|
||||||
|
@ -1238,63 +1238,63 @@ char *prog_name ;
|
||||||
case 0:
|
case 0:
|
||||||
break;
|
break;
|
||||||
case BDF_OPEN_IN :
|
case BDF_OPEN_IN :
|
||||||
USAGE2("%s : The input font file cannot be opened.\"%s\"¡¥\n", prog_name, (snf_in != NULL)? snf_in : "\0" );
|
USAGE2("%s : The input font file cannot be opened.\"%s\"\A1\A5\n", prog_name, (snf_in != NULL)? snf_in : "\0" );
|
||||||
rtn = OPEN_FAIL ;
|
rtn = OPEN_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case BDF_OPEN_OUT :
|
case BDF_OPEN_OUT :
|
||||||
USAGE2("%s : The output font file cannot be opened.\"%s\"¡¥\n", prog_name, (snf_out != NULL)? snf_out : "\0" );
|
USAGE2("%s : The output font file cannot be opened.\"%s\"\A1\A5\n", prog_name, (snf_out != NULL)? snf_out : "\0" );
|
||||||
rtn = OPEN_FAIL ;
|
rtn = OPEN_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|
||||||
case BDF_READ :
|
case BDF_READ :
|
||||||
USAGE2("%s : Information from the font file cannot be extracted.\"%s\"¡¥ \n", prog_name, (snf_in != NULL) ? snf_in : "\0" );
|
USAGE2("%s : Information from the font file cannot be extracted.\"%s\"\A1\A5 \n", prog_name, (snf_in != NULL) ? snf_in : "\0" );
|
||||||
rtn = READ_FAIL ;
|
rtn = READ_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case BDF_WRITE :
|
case BDF_WRITE :
|
||||||
USAGE2("%s : It is not possible to write to the font file.\"%s\"¡¥\n", prog_name, (snf_out != NULL) ? snf_out : "\0" );
|
USAGE2("%s : It is not possible to write to the font file.\"%s\"\A1\A5\n", prog_name, (snf_out != NULL) ? snf_out : "\0" );
|
||||||
rtn = DEVICE_FAIL ;
|
rtn = DEVICE_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case BDF_INVAL :
|
case BDF_INVAL :
|
||||||
USAGE2("%s : The format of the font file is illegal.\"%s\"¡¥ \n", prog_name, (snf_in != NULL) ? snf_in : "\0" );
|
USAGE2("%s : The format of the font file is illegal.\"%s\"\A1\A5 \n", prog_name, (snf_in != NULL) ? snf_in : "\0" );
|
||||||
rtn = 1 ;
|
rtn = 1 ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case BDF_OPEN_HEAD :
|
case BDF_OPEN_HEAD :
|
||||||
USAGE2("%s : The BDF file cannot be opened.\"%s\"¡¥\n", prog_name, (bdf_in != NULL)? bdf_in : "\0" );
|
USAGE2("%s : The BDF file cannot be opened.\"%s\"\A1\A5\n", prog_name, (bdf_in != NULL)? bdf_in : "\0" );
|
||||||
rtn = OPEN_FAIL ;
|
rtn = OPEN_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case BDF_READ_HEAD :
|
case BDF_READ_HEAD :
|
||||||
USAGE2("%s : Information of the BDF file cannot be extracted.\"%s\"¡¥ \n", prog_name, (bdf_in != NULL) ? bdf_in : "\0" );
|
USAGE2("%s : Information of the BDF file cannot be extracted.\"%s\"\A1\A5 \n", prog_name, (bdf_in != NULL) ? bdf_in : "\0" );
|
||||||
rtn = READ_FAIL ;
|
rtn = READ_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case GPF_OPEN_IN :
|
case GPF_OPEN_IN :
|
||||||
USAGE2("%s : The input character pattern file cannot be opened.\"%s\"¡¥\n", prog_name, (gpf_in != NULL) ? gpf_in : "\0" );
|
USAGE2("%s : The input character pattern file cannot be opened.\"%s\"\A1\A5\n", prog_name, (gpf_in != NULL) ? gpf_in : "\0" );
|
||||||
rtn = OPEN_FAIL ;
|
rtn = OPEN_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case GPF_OPEN_OUT :
|
case GPF_OPEN_OUT :
|
||||||
USAGE2("%s : The output character pattern file cannot be opened.\"%s\"¡¥\n", prog_name, (gpf_out != NULL) ? gpf_out : "\0" );
|
USAGE2("%s : The output character pattern file cannot be opened.\"%s\"\A1\A5\n", prog_name, (gpf_out != NULL) ? gpf_out : "\0" );
|
||||||
rtn = OPEN_FAIL ;
|
rtn = OPEN_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case GPF_READ :
|
case GPF_READ :
|
||||||
USAGE2("%s : The character pattern file cannot be read.\"%s\"¡¥\n", prog_name, (gpf_in != NULL) ? gpf_in : "\0" );
|
USAGE2("%s : The character pattern file cannot be read.\"%s\"\A1\A5\n", prog_name, (gpf_in != NULL) ? gpf_in : "\0" );
|
||||||
rtn = READ_FAIL ;
|
rtn = READ_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case GPF_WRITE :
|
case GPF_WRITE :
|
||||||
USAGE2("%s : It is not possible to write to the character pattern file.\"%s\"¡¥\n", prog_name, (gpf_out != NULL) ? gpf_out : "\0" );
|
USAGE2("%s : It is not possible to write to the character pattern file.\"%s\"\A1\A5\n", prog_name, (gpf_out != NULL) ? gpf_out : "\0" );
|
||||||
rtn = DEVICE_FAIL ;
|
rtn = DEVICE_FAIL ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case GPF_INVAL :
|
case GPF_INVAL :
|
||||||
USAGE2("%s : The format of the character pattern file is illegal.\"%s\"¡¥\n", prog_name, (gpf_in != NULL) ? gpf_in : "\0" );
|
USAGE2("%s : The format of the character pattern file is illegal.\"%s\"\A1\A5\n", prog_name, (gpf_in != NULL) ? gpf_in : "\0" );
|
||||||
rtn = 1 ;
|
rtn = 1 ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -1566,8 +1566,8 @@ char *com;
|
||||||
errno = 0;
|
errno = 0;
|
||||||
if ( chown (fname, owner, group) != 0) {
|
if ( chown (fname, owner, group) != 0) {
|
||||||
USAGE2("%s : Failed in setteing of the owner and the group of the following files. \tPlease change to the file of the owner and the group of following ID \tafter the inquiry the system manager.\"%s\"\n", com, fname );
|
USAGE2("%s : Failed in setteing of the owner and the group of the following files. \tPlease change to the file of the owner and the group of following ID \tafter the inquiry the system manager.\"%s\"\n", com, fname );
|
||||||
USAGE1("\t\t Owner ID ¡§%d\n", (int)owner);
|
USAGE1("\t\t Owner ID \A1\A7%d\n", (int)owner);
|
||||||
USAGE1("\t\t Group ID ¡§%d\n", (int)group);
|
USAGE1("\t\t Group ID \A1\A7%d\n", (int)group);
|
||||||
return( 1 );
|
return( 1 );
|
||||||
}
|
}
|
||||||
return( 0 );
|
return( 0 );
|
||||||
|
@ -1643,7 +1643,7 @@ char *cmd;
|
||||||
|
|
||||||
for ( ; end = ( char * )strchr( path, ':' ); path = end + 1 ) {
|
for ( ; end = ( char * )strchr( path, ':' ); path = end + 1 ) {
|
||||||
chr_sv = *end;
|
chr_sv = *end;
|
||||||
*end = NULL;
|
*end = 0;
|
||||||
AllocString( cmd_path, path, NULL ) ;
|
AllocString( cmd_path, path, NULL ) ;
|
||||||
*end = chr_sv;
|
*end = chr_sv;
|
||||||
|
|
||||||
|
|
|
@ -376,7 +376,7 @@ int buttons_cnt;
|
||||||
static Atom
|
static Atom
|
||||||
DeleteWindowAtom()
|
DeleteWindowAtom()
|
||||||
{
|
{
|
||||||
static Atom delatom = NULL;
|
static Atom delatom = 0;
|
||||||
if (! delatom){
|
if (! delatom){
|
||||||
delatom = XInternAtom(XtDisplayOfObject(toplevel),
|
delatom = XInternAtom(XtDisplayOfObject(toplevel),
|
||||||
"WM_DELETE_WINDOW", False);
|
"WM_DELETE_WINDOW", False);
|
||||||
|
@ -532,7 +532,7 @@ int offset;
|
||||||
XmNleftAttachment, XmATTACH_WIDGET,
|
XmNleftAttachment, XmATTACH_WIDGET,
|
||||||
XmNleftWidget, ref,
|
XmNleftWidget, ref,
|
||||||
XmNleftOffset, offset,
|
XmNleftOffset, offset,
|
||||||
0);
|
NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -543,7 +543,7 @@ int offset;
|
||||||
XtVaSetValues( w,
|
XtVaSetValues( w,
|
||||||
XmNleftAttachment, XmATTACH_FORM,
|
XmNleftAttachment, XmATTACH_FORM,
|
||||||
XmNleftOffset, offset,
|
XmNleftOffset, offset,
|
||||||
0);
|
NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -556,7 +556,7 @@ int offset;
|
||||||
XmNtopAttachment, XmATTACH_WIDGET,
|
XmNtopAttachment, XmATTACH_WIDGET,
|
||||||
XmNtopWidget, ref,
|
XmNtopWidget, ref,
|
||||||
XmNtopOffset, offset,
|
XmNtopOffset, offset,
|
||||||
0);
|
NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -567,7 +567,7 @@ int offset;
|
||||||
XtVaSetValues( w,
|
XtVaSetValues( w,
|
||||||
XmNtopAttachment, XmATTACH_FORM,
|
XmNtopAttachment, XmATTACH_FORM,
|
||||||
XmNtopOffset, offset,
|
XmNtopOffset, offset,
|
||||||
0);
|
NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -580,7 +580,7 @@ int offset;
|
||||||
XmNrightAttachment, XmATTACH_WIDGET,
|
XmNrightAttachment, XmATTACH_WIDGET,
|
||||||
XmNrightWidget, ref,
|
XmNrightWidget, ref,
|
||||||
XmNrightOffset, offset,
|
XmNrightOffset, offset,
|
||||||
0);
|
NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -591,7 +591,7 @@ int offset;
|
||||||
XtVaSetValues( w,
|
XtVaSetValues( w,
|
||||||
XmNrightAttachment, XmATTACH_FORM,
|
XmNrightAttachment, XmATTACH_FORM,
|
||||||
XmNrightOffset, offset,
|
XmNrightOffset, offset,
|
||||||
0);
|
NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -602,7 +602,7 @@ int offset;
|
||||||
XtVaSetValues( w,
|
XtVaSetValues( w,
|
||||||
XmNbottomAttachment, XmATTACH_FORM,
|
XmNbottomAttachment, XmATTACH_FORM,
|
||||||
XmNbottomOffset, offset,
|
XmNbottomOffset, offset,
|
||||||
0);
|
NULL);
|
||||||
}
|
}
|
||||||
#endif /* not USE_MACRO */
|
#endif /* not USE_MACRO */
|
||||||
|
|
||||||
|
@ -641,7 +641,7 @@ String str;
|
||||||
{
|
{
|
||||||
XmString cs;
|
XmString cs;
|
||||||
cs = XmStringCreateLocalized(str);
|
cs = XmStringCreateLocalized(str);
|
||||||
XtVaSetValues( w, XmNlabelString, cs, 0);
|
XtVaSetValues( w, XmNlabelString, cs, NULL);
|
||||||
XmStringFree( cs );
|
XmStringFree( cs );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -652,7 +652,7 @@ String str;
|
||||||
{
|
{
|
||||||
XmString cs;
|
XmString cs;
|
||||||
cs = XmStringCreateLocalized(str);
|
cs = XmStringCreateLocalized(str);
|
||||||
XtVaSetValues( w, XmNlabelString, cs, 0);
|
XtVaSetValues( w, XmNlabelString, cs, NULL);
|
||||||
XmStringFree( cs );
|
XmStringFree( cs );
|
||||||
XmUpdateDisplay(w);
|
XmUpdateDisplay(w);
|
||||||
}
|
}
|
||||||
|
@ -680,7 +680,7 @@ char *str;
|
||||||
|
|
||||||
if (! str || ! *str) return;
|
if (! str || ! *str) return;
|
||||||
|
|
||||||
for( p=str, s=buf, lw=0; *p != NULL; ){
|
for( p=str, s=buf, lw=0; *p != 0; ){
|
||||||
|
|
||||||
if ( (*p == '\n') || (charcnt <= lw) ){
|
if ( (*p == '\n') || (charcnt <= lw) ){
|
||||||
*s = '\n'; /* new line */
|
*s = '\n'; /* new line */
|
||||||
|
@ -692,7 +692,7 @@ char *str;
|
||||||
|
|
||||||
lw += wcwidth( wc );
|
lw += wcwidth( wc );
|
||||||
}
|
}
|
||||||
*s = NULL;
|
*s = 0;
|
||||||
|
|
||||||
cs = XmStringCreateLocalized(buf);
|
cs = XmStringCreateLocalized(buf);
|
||||||
XtVaSetValues(st, XmNlabelString, (XtArgVal)cs, (String)0 );
|
XtVaSetValues(st, XmNlabelString, (XtArgVal)cs, (String)0 );
|
||||||
|
@ -808,13 +808,13 @@ XtPointer clientdata;
|
||||||
Dimension bbw, mw, sw, cw;
|
Dimension bbw, mw, sw, cw;
|
||||||
|
|
||||||
|
|
||||||
XtVaGetValues(w, XmNchildren, &child, XmNnumChildren, &num, 0);
|
XtVaGetValues(w, XmNchildren, &child, XmNnumChildren, &num, NULL);
|
||||||
XtVaGetValues(XtParent(w),
|
XtVaGetValues(XtParent(w),
|
||||||
XmNwidth, &bbw,
|
XmNwidth, &bbw,
|
||||||
XmNmarginWidth, &mw,
|
XmNmarginWidth, &mw,
|
||||||
XmNshadowThickness, &sw,
|
XmNshadowThickness, &sw,
|
||||||
0);
|
NULL);
|
||||||
XtVaGetValues(child[0], XmNwidth, &cw, 0);
|
XtVaGetValues(child[0], XmNwidth, &cw, NULL);
|
||||||
XtVaSetValues(w, XmNwidth, ((int)bbw-2*((int)mw+(int)sw)), NULL);
|
XtVaSetValues(w, XmNwidth, ((int)bbw-2*((int)mw+(int)sw)), NULL);
|
||||||
XtVaSetValues(child[0], XmNx,
|
XtVaSetValues(child[0], XmNx,
|
||||||
((((int)bbw-2*((int)mw+(int)sw))-(int)cw)/2), NULL);
|
((((int)bbw-2*((int)mw+(int)sw))-(int)cw)/2), NULL);
|
||||||
|
|
Loading…
Reference in a new issue